Search:

Type: Posts; User: gaah

Search: Search took 0.01 seconds.

  1. Replies
    16
    Views
    1,883

    pointers to arrays

    Hey! I have some problems with arrays and pointers... The code below should explain what I'm trying to do but it seems I'm missing something? Please help!!! Ie, how do I pass a pointer to an array as...
  2. Why? fgetc returns a char what I know of? And I...

    Why? fgetc returns a char what I know of? And I just discovered that my code works if I add another integer (a dummy integer) below that int companies... I don't understand this...
  3. weird error..., I have no idea about this one...

    FILE *f = fopen(filename, "r");
    while(fgetc(f)<=0x20);
    while(fgetc(f)!=0x0A);
    int rows = 0;
    int collumns = 0;
    int companies = 0;
    char current = 0x00;
    char old = 0x00;
    string currentcomp = "";...
  4. Thread: Makefile

    by gaah
    Replies
    2
    Views
    1,120

    ahh! Of course, thank you! :-)

    ahh! Of course, thank you! :-)
  5. Thread: Makefile

    by gaah
    Replies
    2
    Views
    1,120

    Makefile

    I'm doing this project with fltk as gui. I use mingw and msys as compiler, meaning regular makefiles. But I get this weird error that I just can't figure out...

    This is how my Makefile looks like:...
  6. Replies
    2
    Views
    1,359

    reading excel files...

    Hey! I need help! How can I read information from an excel file into my c/c++ code? I'm using mingw as compiler through msys. Any recomended websites or information would be great!
  7. Replies
    9
    Views
    9,597

    Splitting up int16_t to two int8_t

    I try to figure out how to split up one int16_t into two int8_t... But I can't figure it out.

    Well actually, I have a string containing some stuff. Then I have a representation of two chars in an...
  8. Thread: Binary xor

    by gaah
    Replies
    9
    Views
    1,272

    But I have it in a string. Can I have unsigned...

    But I have it in a string. Can I have unsigned chars in a string?
  9. Thread: Binary xor

    by gaah
    Replies
    9
    Views
    1,272

    Yes, that worked... But my main concern is that...

    Yes, that worked... But my main concern is that the string s will be in the right format, meaning only 0x83. And how come it printed it out correctly before I did the xor?
  10. Thread: Binary xor

    by gaah
    Replies
    9
    Views
    1,272

    string s = "pqr"; printf("%X %X %X...

    string s = "pqr";
    printf("%X %X %X \n",s[0],s[1],s[2]);
    s[0] = (char)(PWD[0] ^ 0xF3);
    printf("%X %X %X \n",s[0],s[1],s[2]);

    Like that!
  11. Thread: Binary xor

    by gaah
    Replies
    9
    Views
    1,272

    Binary xor

    I need to do something similar to this:

    string s = "pqr";
    s[0] = (char)(s[0] ^ 0xF3);

    s[0] has value 0x70 from the begining and I want the result to be 0x83 after running the code. But I get...
  12. Replies
    9
    Views
    5,589

    what do you mean bit fields?

    what do you mean bit fields?
  13. Replies
    9
    Views
    5,589

    From what I've read a char isn't always one byte,...

    From what I've read a char isn't always one byte, and even if it were, one byte wouldn't always be eight bits... Don't know how accurate that is, but better to be safe than sorry!

    How do you mean...
  14. Replies
    9
    Views
    5,589

    Cross platform portability, about data types...

    I'm writing an im-client that should connect to the icq server, meaning I need to fiddle around with the oscar/flap/snac/tlv protocols/stuff. Let's say a certain tlv needs to be four byte, no more ,...
  15. Replies
    8
    Views
    1,980

    http://www.ecst.csuchico.edu/~beej/guide/net/html/...

    http://www.ecst.csuchico.edu/~beej/guide/net/html/

    Read all of that really throughly and you will understand most of your questions, and allot of more! If you don't get it at once, read it again...
Results 1 to 15 of 15