Weird characters in g++ output

When using Arch and ssh/xterm to remotely logging into an Ubuntu machine (university lab computer)  to run g++, the complier output (when there's a compile error) has an accented character "a hat" (i.e. the character "a" with a caret symbol above it) in place of all function and variable names .
For instance, it will output:
file.cc : In function <a-hat symbol>
file.cc:19: error: <a-hat> was not declared in this scope.
when it should have outputted:
file.cc : In function main
file.cc:19: error: idx was not declared in this scope.
NOTE:  I don't know how to enter special characters in a post, so I entered <a-hat> instead of the actual special character.
Now, it doesn't happen when I log into the Ubuntu machine from another Ubuntu machine.  It only happens when the client is Arch.  I am 99% certain that this is a problem with Ubuntu and not Arch.  But, I don't have root on the Ubuntu machine because it's the school's computer, so I can't fix it.
Does anyone know if there's something I can try on the Arch box that will fix this display problem?
EDIT:  Sorry, I should've posted this in the Workstation thread maybe.  Admins, please kindly move it if you see fit.
Last edited by battra (2007-06-06 03:55:20)

grepper and Tucos in #conky solved the issue for me.  Apparently, the "weird characters" was a color code.  I had to pipe:
sed -r "s/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]//g"
in conkyrc to remove color codes.

Similar Messages

  • Java - InputStream - Weird Characters in the Output!

    Hi,
    I have a software which outputs lines of numbers one by one. In another java program, I use BufferedReader as follows:
    BufferedReader input = new BufferedReader(new InputStreamReader(pr.getInputStream(),"US-ASCII"));
    where pr is the process which runs the software. For each line in the output stream, I try to check whether the first number in the line is greater than a certain value and if it is, I write to another file.
    The problem is, when I run the software repeatedly (in a linux cluster) like 10 simulations simultaneously, one of them have got @^@^.... characters followed by some huge numbers. So, I tried eliminating that line alone by using String.matches command but now, it seems even after that I get the error - so, I think it might mean that it is actually during the writing process that the problem occurs. I use BufferedWriter like the following to write it: (I do flush it after writing.)
    BufferedWriter out=new BufferedWriter(new FileWriter(tmp_file));
    I would greatly appreciate if someone can help. This thing really seems to be a huge bottleneck!
    Thanks,
    Senthil

    Hi ejp! Thanks - here is the code!
    import java.io.BufferedReader;
    import java.io.FileOutputStream;
    import java.io.InputStreamReader;
    import java.io.PrintStream;
    import java.io.*;
    import java.util.*;
    //call the class file with the input xml file to simulate
    public class RunSim {
    public static void main(String[] args) {
    String[] xmlFiles = new String[] { "/home/senthil/Simulator/Dessa1.4/" args[0]};
    Scanner input=null;
    FileWriter ofw=null;
    PrintWriter out=null;
    for(String file:xmlFiles) {
    try {
    String[] command = {"java","Test",file, "10000"};
    Process pr = Runtime.getRuntime().exec(command); // run the command
    input = new Scanner(new InputStreamReader(pr.getInputStream()));
    String line=null;
    ofw=new FileWriter(file"_out.txt");
    out=new PrintWriter(ofw);
    while(input.hasNextLine()) {
    line=input.nextLine();
    System.out.println(line);
    if(line.matches("[0-9.\\s]*")) { // I included this as I didn't want the '@^' character - but still, it is being produced.
    out.println(line);
    out.flush();
    String[] str = line.split(" ");
    if(!line.equals("Badly formatted XML file")){
    if((Float.parseFloat(str[0]) >= 196)) //this is the limit upto which the process has to be run
    pr.destroy();
    else
    continue;
    out.close();
    int exitVal = pr.waitFor();
    System.out.println("Exited with error code "+exitVal);
    } catch(Exception e) {
    System.out.println(e.toString());
    e.printStackTrace();
    }

  • Why does my output give weird characters?

    import java.util.Scanner;
    public class SDTester{
         public static void main(String[] args){
              String message;
              Scanner scan = new Scanner(System.in);
              BinarySearchTree t = new LinkedBinarySearchTree();
              System.out.println("Enter command");
              message = scan.nextLine();
    }Can someone explain why my output for this when typing quit is:
    Enter command
    quit�:

    Yeah its what I typed in. The "a" is not the only mysterious part. Theres also that upside down L type thing and the colon. Sometimes theres extra letters. Im running on windows vista.
    Its weird when I copy the output some of the "weird" characters dont show up.
    EDIT: Its only with inputted text. I did a simple println statement and it was fine but the quit when typed in and the quit when printed out from the variable "message" give the weird text:
    ---------- Capture Output ----------
    "C:\Program Files\Java\jdk1.6.0_02\bin\java.exe" SDTesterEnter command
    quit�:
    quit�:
    Hello everybody
    Terminated with exit code 0.Edited by: McCloud7 on Dec 16, 2007 7:29 PM
    Edited by: McCloud7 on Dec 16, 2007 7:31 PM

  • Weird Characters appering in the browser

    My company's product help file is generated in WebHelp, but
    on the web I see in some pages showing some weird characters. When
    I checked my source file as actually what characters are they in
    the file, I see that the trademark signs (TM) , single quotes, and
    double quotes are appearing as a ? inside a diamond. I went through
    the script generated by Webhelp and see the character set Webhelp
    is using as charset=windows-1252, Can't we change it to UTF-8 so
    that its a universal character set and is recognize on all
    platforms and browsers.
    Please let me know if there is a solution.
    Thanks,
    Ashish

    UTF-8 is the norm with RH7. If you cannot upgrade, or do not
    want to, take a copy of your output and try changing it manually in
    one topic. If it works then use a multi file find and replace tool.

  • Weird characters when generating WebHelp from a word document

    Hello,
    First of all, I'm using RoboHelp 6.
    I've seen many posts about this subject, but none with the same version.
    I've generated a WebHelp from a word document, that contains accentuated characters (french).
    When viewing that help from my local machine, it's ok.
    When viewing that help from a web server, it displays weird characters.
    I'd like to change the encoding to UTF8, in my web help.
    I've seen (if I understood well) that we could change the output charset when generating a web help, but only from the RoboHelp 7 version.
    How can I do such a thing on  RoboHelp 6 version ?
    I've tried to add <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> in many htm files, without success.
    Any ideas ?
    Thanks a lot
    Regards

    Hello
    Thank you for answering me.
    There is no way to do it using RoboHelp ?
    Thkx

  • Offline approval - weird characters in Outlook

    Hi all,
    We're on SRM 5.0, Server 550, SP12.
    Scenario: offline approval of Shopping Carts
    After running report RBBP_NOTIFICATION_OFFAPP, approver is getting an e-mail in Outlook 2003 with some weird characters:
    **START**
    Â
        The following requires processing:
    Â
        1 . Approve shopping cart of Shopper with value 64,78 USD
       
    Â
    Â
        Use the following link to log on to the system and carry out the approval online:
        Log on
    Â
    Â
        To approve or reject directly from this e-mail, select one of the following links:
    Approve by E-mail   Reject by E-mail   Â
    **END**
    When I look at the same message in , these characters are not visible; but there seem to be spaces/blanks in those spots. Looks like Outlook is substituting spaces for some other character.
    Also, there're some extra blank lines, which we would like removed.
    Any ideas how to get rid of the unwanted characters and unnecessary lines, besides BAdI implementation?
    Cheers,
    Serguei

    Hi,
    Please check the foll note:
    Note 1100912 - E-mail messages for work items with incorrect line break
    Also,sometimes some junk characters are inserted into the offline mail if the required services(for the generation of mail ) are not active in transaction SICF.
    Please see whether the following path is active in SICF:
    SAP/BC/BSP/SAP/SMART_FORMS/DEFAULT.CSS
    If the above service is not activated,then activate that and re-test.
    Last option would be to implement the BADI BBP_OFFLINE_APP_BADI (method ~MAIL_DATA_GET) to remove the unwanted characters.
    BR,
    Disha.

  • My Mac won't read cyrillic in certain files and displays instead weird characters like this: "–í–µ-Ç–µ-Ä –ø-Ä–æ–¥–∏-Ä–∞–µ-Ç –¥–æ –∫–æ-Å-Ç–µ–π." Any ideas why this might be or how I can solve it?

    Yesterday I extracted the subtitles of an MKV file to try and print them. Unfortunately, when I open the .srt file with any text processor, it displays weird characters like the ones included in the title:
    "–û–±—ã–≤–∞—Ç–µ–ª–∏ –ø–µ—á–∞–ª—å–Ω—ã.
    –í–µ—Ç–µ—Ä –ø—Ä–æ–¥–∏—Ä–∞–µ—Ç –¥–æ –∫–æ—Å—Ç–µ–π."
    I thought this had to do with it being an .srt file, but just now I encountered the same problem with an Excel file.
    Any ideas why this might be or suggestions as to how to solve it?
    Thanks in advance,
    Mario

    It looks like an encoding problem.  You should try opening the file in a text editor where you can choose one of the various possible cyrillic encodings (utf-8, koi8-r, iso-8859-5, win-1251, MacCyrillic)

  • Square boxes instead of Japanese characters in pdf output of a crystal rep

    Hi All,
    Did anyone of you ever faced such an issue, where the pdf output of a crystal report shows square boxes instead of Japanese characters when the output is saved in pdf. However the crystal report output looks perfect. I have saved the ouput in xls and rtf formats the characters look perfect as required, the issue we have is when the output is saved as pdf.
    I have language pack installed on my machine.
    My guess is that the few Character's width is not sufficient and few Characters in other fields appear perfect in pdf. I have to test this, it might take few days before I can access this report. Before that I want to gather information. If anyone has solution to this issue please let me know.
    Thanks,
    Ravi

    Hi,
    Could you please answer the following questions
    1.What version of Crystal Reports are you using?
    Go to Help-> About to find out.
    2.What is the font you are using on the report?
    Try to change the font style to MS Gothic or Arial Unicode MS, most preferably MS Gothic.
    And export the report to PDF format.
    This may help you
    Thanks,
    Praveen G

  • Japanese lyrics shown on iPhone become weird characters after some number of plays

    I put in lyrics for my Japanese songs both the kanji/kana and romaji. There have been no problems before this. But somehow I suppose after the newest iTunes released I added some new songs and there were two of them that I added lyrics into them. At first their lyrics were shown properly on my iPhone screen. But after some time the kanji/kana became some weird characters. I checked the lyrics in iTunes and there seemed to be no problems at all with my lyrics. I needed to delete the song from both my phone and my iTunes library and re-add then re-synced it again. (just deleting the song from the phone and then re-synced it didn't help.) Then again, today the lyrics became weird again. I don't really understand. It would become very annoying if this keeps going on. I would appreciate any advice and help. Thank you very much.

    I just tried this with my iPhone 4 and it also didn't work.  This is how it failed:
      - Select "shared".
    - The "pie" start to grow, got to about 1/3, then crashed without
        bringing in the shared content.
    - After that, the library appeared in list, but I couldn't select
        it at all anymore.
    Then I tried it with my iPad.  The pie got to the same point, sat
    there for a long time, then completed and worked fine.
    I did a hard reset of the phone and tried again, this time it
    behaved like the iPad and worked fine.
    Not sure whether it was the hard reset or whether sharing with
    another device "woke something up", but in any event it works
    now and I can't get it to break again.
    Note, I only use sharing for movies, since I have Music Match
    (which works *great* for me, even on 3G).
    Specs:
      Sharing: 2.7 GHz iMac i5, OS 10.6.8
      Clients: iPhone 4
                  4th gen iPad
    Everything (including iTunes) patched to the latest.

  • Weird characters appear after write to a file

    Here is my story:
    I open a file using RandomAccessFile to replace some characters inside it. Let's say I have in the file string 4000, I replace it by string 400. It works fine.
    Now if I replace this number by string 40000, when I check the text file, some weird characters like ^M appear everywhere at the end of lines.
    What's the reason and how to solve it? I believe there is some invisible characters at the end of string 4000 that causes the problem.
    Note that I use function writeBytes to write strings into the file.

    public static void changeFileRAF(String sFile, String paramName, String paramValue) {
    try {
    RandomAccessFile rf = new RandomAccessFile(sFile, "rws");
    String currentLine;
    long pos;
    while (true) {
    pos = rf.getFilePointer();
    currentLine = rf.readLine();
    if (currentLine == null)
    break;
    if (currentLine.trim().startsWith(paramName)) {
    rf.seek(pos);
    char[] replaceLine = currentLine.toCharArray();
    char[] value = paramValue.toCharArray();
    int i = 0;
    //pass all white space characters
    while (i < replaceLine.length && Character.isWhitespace(replaceLine)) {
    i++;
    //pass all characters representing tag name
    while (i < replaceLine.length && !Character.isWhitespace(replaceLine[i])) {
    i++;
    //again, pass all white space characters
    while (i < replaceLine.length && Character.isWhitespace(replaceLine[i])) {
    i++;
    if (i == replaceLine.length) {//no value, do nothing                                                           
    return;
    int oldValueLength = replaceLine.length - i;
    String newLine = System.getProperty("line.separator");
    if (oldValueLength >= value.length) {
    System.out.println("different: " + (oldValueLength - value.length));
    for (int j = 0; j < value.length; j++)
    replaceLine[j + i] = value[j];
    for (int j = value.length; j < oldValueLength; j++)
    replaceLine[j + i] = ' ';
    rf.writeBytes(String.copyValueOf(replaceLine));
    else {
    System.out.println("old value length: " + oldValueLength);
    System.out.println("new value length: " + value.length);
    char[] compensation = new char[value.length - oldValueLength];
    for (int j = 0; j < oldValueLength; j++)
    replaceLine[j + i] = value[j];
    for (int j = oldValueLength; j < value.length; j++)
    compensation[j - oldValueLength] = value[j];
    System.out.println("it is " + String.copyValueOf(replaceLine) + String.copyValueOf(compensation));
    rf.writeBytes(String.copyValueOf(replaceLine) + String.copyValueOf(compensation));
    break;
    rf.close();
    } catch (IOException e) {
    System.out.println(e.getMessage());
    I hope it's not too long.

  • If i got incorrect characters in the output of sap script? HOW TO CORRECT I

    If i got incorrect characters in the output of sap script? HOW TO CORRECT IT?

    Hi Sunil,
    Debug the script and check where exactly those are getting populated. Definately you will get it. Check the conversion parts means character to numeric conversion.
    If your version is 4.7E then select unicode check box in the reports attributes. It will display the error message so that we can solve very easily.Hope this helps you, reply for queries, Shall post you the updates.
    Regards. 
    Kumar. .

  • Why has my use of the apostrophe started inserting a string of weird characters on my iPad?

    My iPad has recently started replacing the apostrophe with a string of weird characters (something like &amp;39; or similar) when I post a comment on Facebook or YouTube. Why is it, and how do I get rid of it? Anybody know?
    (The apostrophe appears as normal when I'm still typing; it's only when I send / transmit the the post that it appears.)

    On the other hand if you want to fix it, it's a simple as going here:
    http://www.adobe.com/products/activation/
    and starting a chat session to get them to reset your activations.

  • Weird characters in known_hosts file

    We have a Solaris 9 Client system that does ssh to other Solaris servers.
    StrictHostKeyChecking is set to "No" in /etc/ssh_known_hosts.
    Even when the public host key of the servers do not change we see that there are multiple entries in $HOME/.ssh/known_hosts file of the client.
    How can this happen?
    And some times, we have weird characters in place of the ip address and encryption algorithm, while the actual key is properly written into known_hosts file.
    How these weird characters are put into the known_hosts file?
    If anyone can provide the answers, it will be of great help.
    Thanks in advance.

    not sure i follow fully, can you check for this setting:
    HashKnownHosts yes
    in ssh_config. this will hash keys in known_hosts to make it unreadable...

  • Weird characters before the xml start tag on Host

    When we load xml generated in Biztalk into an OS/400 Host environment, they always have some weird characters before the declaration (<?xml) causing the host program to fail. The characters look like gibberish from another planet (not really..look like
    some binary encoding). Can one of the experts please point me to what must be changed?

    If you look at the message using a hex editor, the UTF-8 BOM (Byte Order Mark) is EF BB BF, if you are using Unicode, the BOM is FE FF or FF FE (depending on little or big Endian encoding).
    If you "Stop" your send port and run a test, you can view the suspended message body in hex and determine if these characters are a BOM.
    David Downing... If this answers your question, please Mark as the Answer. If this post is helpful, please vote as helpful.

  • Weird characters in Ultrabeat

    Sorry if this has been posted elsewhere but I've recently started to get some weird characters when opening an Ultrabeat instrument (see attached screenshots).
    /Users/neilmorgan/Desktop/Screen shot 2010-12-27 at 16.53.59.png
    /Users/neilmorgan/Desktop/Screen shot 2010-12-27 at 16.54.56.png
    They're different each time and they seem not to affect the sound, but does anyone have any ideas of how to rid my system of them?
    Message was edited by: SwiftyM
    Message was edited by: SwiftyM
    Message was edited by: SwiftyM

    For instance, did you mean something like this:
    https://skitch.com/yorick75/rx46f/characters
    I've been getting those kind of 'weird characters' in the Ultrabeat pattern menu as well, but only recently. If that is the same case as yours, yes, it doesn't affect the sound or functionality of anything in Ultrabeat; however, it is annoying and a bit confusing when you want to choose a sample pattern or if you want to create a new one because the whole menu window looks 'jumbled up' with those odd characters. I have no idea what causes the display of these 'weird characters'. I would like to know if there's some way to fix this. Hopefully someone else has come upon this and might read this post too. By the way, in my case, this happens in Logic 8. So I don't know if anyone using Logic 9 has encountered a similar problem.

Maybe you are looking for

  • Performance hit in audio playback in Solaris 10

    Hi, I've noticed while trying out the Solaris 10 beta 72 that the audio playback quality took a major hit since Solaris 9. I was hoping that this would go away in the Solaris 10 release, but it's not the case. If I try to play an .mp3 file with mpg12

  • Read file  : File name conatins the Time stamp from payload

    Hi I have to scenario where i am creating file name  based on the payload field ( Date/time), theni have to pick up the files based on the File Name : Ex:  0212200910:01:02        0212200910:01:03        0212200910:01:01 then the sender adapter shoul

  • Impossible to access a bean from a JSP in NES 4.0

    We are trying to use a bean in a JSP using the common tag <jsp:useBean id="... /> in a Netscape Enterprise Server 4.0. Always we obtain the same error: "JSP compilation error: java.lang.Exception: JSP parse error (line 43) - Incomplete tag ending of

  • Iphoto 08 image corruption- Spot heal tool

    I have retouched a batch of tiff photos using the Spot healing tool. I was perfectly happy with the quality of the edit as i saved them. On reopening the images later i noticed that there are blurred/distorted marks all over the images. I can revert

  • Persistent Behavior Tracking (Portal4.0) problem with MSSQL 2000

    Hi, We are having some problems with the Presistent Behavior Checking fucntion. When we turned that on, we found out that once we add the 'com.bea.b13n.trackig.listeners.BehaviorTrackingListener class' to the event service, navigating the samples tem