Search:

Type: Posts; User: Deckard

Page 1 of 20 1 2 3 4

Search: Search took 0.02 seconds.

  1. Replies
    10
    Views
    1,369

    It's just another way to skin the cat; it's not...

    It's just another way to skin the cat; it's not criticism.
  2. Replies
    10
    Views
    1,369

    I suppose you could always start at the NULL and...

    I suppose you could always start at the NULL and work your way back to the first occurance of the slash and save yourself the function call (not that there's anything wrong with calling strrchr()).
  3. Replies
    9
    Views
    1,073

    It's not too late to switch majors.

    It's not too late to switch majors.
  4. Replies
    9
    Views
    1,073

    If you post what you've got so far, and explain...

    If you post what you've got so far, and explain where you're stuck, we can help you out.
  5. Replies
    1
    Views
    1,000

    The answer depends upon what environment you're...

    The answer depends upon what environment you're using. Look into the ncurses library if you're on *nix.
  6. Replies
    6
    Views
    1,949

    " Source in your custom filetypes as given below...

    " Source in your custom filetypes as given below -
    so $HOME/.vim/myfiletypes.vimThat looks suspicious. Could it be overriding the vim defaults? Also, try :help from within vim. If that doesn't work,...
  7. Replies
    6
    Views
    1,949

    I have my system setup to do just that. Here's...

    I have my system setup to do just that. Here's the .vimrc from my home directory:



    " .vimrc
    " Last updated August 14, 2005 by jdeckard
    set shiftwidth=3
    set shiftround
    set expandtab
    set...
  8. Replies
    6
    Views
    1,195

    Also, Wraithan provides much faster answers than...

    Also, Wraithan provides much faster answers than I do ;)
  9. Replies
    6
    Views
    1,195

    Playing around is a great way to learn. It...

    Playing around is a great way to learn.

    It looks like you're trying to return lpBits:

    return lpBits;...and you already know what it is:

    BYTE *lpBits = malloc(size);...so, should...
  10. Thread: I need help!!!

    by Deckard
    Replies
    11
    Views
    1,077

    The sign bit isn't a factor in this situation. ...

    The sign bit isn't a factor in this situation.

    However, as a general rule (and to benefit those who may not know why), sure: use unsigned integers when using integers as bit fields. Why? Because...
  11. Thread: I need help!!!

    by Deckard
    Replies
    11
    Views
    1,077

    Here's a rough draft that goes backwards and...

    Here's a rough draft that goes backwards and always displays a fixed length field, but it should help:


    void printSubsets( int range )
    {
    int index;
    int field; /* assuming 26-bits or more...
  12. Replies
    3
    Views
    899

    pinfun() keeps calling itself until i > n*n,...

    pinfun() keeps calling itself until i > n*n, incrementing x by three each time. By the time i is larger than n*n, x is larger than the number your user entered. That becomes a factor the first time...
  13. Replies
    23
    Views
    2,126

    I've never thought about it before. To be...

    I've never thought about it before. To be honest, I don't think of my thoughts as images or words. They're "just there". It's probably a linked list gone horribly wrong.

    I do know that when I'm...
  14. Thread: error prob

    by Deckard
    Replies
    5
    Views
    1,073

    Perhaps you could post the source that gcc...

    Perhaps you could post the source that gcc doesn't like. I suspect you've specified main with a return type of void.

    EDIT: Oops, problem solved a good ten minutes ago :rolleyes:
  15. Replies
    2
    Views
    1,100

    sys_execve (11)

    sys_execve (11)
  16. Replies
    11
    Views
    1,605

    fork() returns the process identifier of the...

    fork() returns the process identifier of the child to the parent and zero to the child itself. fork() will return -1 if an error occurs, which is always good to know about. Call fork() and test the...
  17. Replies
    8
    Views
    6,755

    Correct, and it doesn't change the flow of...

    Correct, and it doesn't change the flow of execution. I'm sure you can guess what command takes you back down the stack.
  18. Replies
    8
    Views
    6,755

    You just need to go "up" in the stack to bring...

    You just need to go "up" in the stack to bring ptr back in scope.


    jdeckard@bender ~/test $ cat gdbfun.c
    void myfunc( void )
    {
    int x;

    x = 1 + 1;
    }
  19. Thread: float to int 2

    by Deckard
    Replies
    4
    Views
    2,594

    I'm glad to see you've got it figured out. For...

    I'm glad to see you've got it figured out. For what it's worth, there's nothing wrong with tracking the remaining number of cups with x or cups (no need for y).



    *cups = x;
    *cups -=...
  20. Thread: float to int 2

    by Deckard
    Replies
    4
    Views
    2,594

    Your variables for gallons, quarts, pints, and...

    Your variables for gallons, quarts, pints, and cups are not always given a value before you print them.

    -----

    Bonus hint:

    if ( expr )
    statement;
    statement;
    is not the same as
  21. Replies
    8
    Views
    1,255

    If the legacy code returns value to your code...

    If the legacy code returns value to your code (and I don't know if it does), would it make sense to keep the second table in your new code? You could get the result of the first table by calling the...
  22. Replies
    8
    Views
    1,255

    I'd like to get a better understanding of why the...

    I'd like to get a better understanding of why the legacy function won't work for you as-is. I'm guessing that you've decided index_table needs to be an array of function pointers because it solves a...
  23. Replies
    2
    Views
    1,038

    It would help to post the errors. if (...

    It would help to post the errors.


    if ( sscanf( buff, "%d/%d/%d", &d, &m, &y ) == 3 ) {
    /* got 3 ints */
    if ( d >= 1 && d <= 31 ) /* etc etc */
    }This is a problem. The...
  24. Replies
    9
    Views
    1,346

    If you don't mind using the Microsoft Foundation...

    If you don't mind using the Microsoft Foundation Classes (and C++, for that matter), take a look at OpenProcess(), ReadProcessMemory(), and WriteProcessMemory().
  25. Thread: Best Uptime

    by Deckard
    Replies
    25
    Views
    3,176

    I believe we have a system at over 400 days, but...

    I believe we have a system at over 400 days, but I happened to be on this box at the moment.
Results 1 to 25 of 500
Page 1 of 20 1 2 3 4