Search:

Type: Posts; User: youjustreadthis

Search: Search took 0.01 seconds.

  1. C - Program freezes; futex_wait_queue_me

    I am having problems with my program going in futex_wait_queue_me mode.

    I have included the code in its entirety so that you can test it if you want. Keep in mind that this is nowhere near...
  2. Inserting values in functions using getopt_long

    Hi,

    I'm trying to create a program that will be able to send tcp packets using raw sockets. In order to do so I need to pass values like ip-addresses and port numbers to the send_tcp function,...
  3. Just one more thing regarding optget(), more...

    Just one more thing regarding optget(), more specifically optget_long(). Why are the flags necessary? as far as I can see they don't do much.


    static struct option long_options[] =
    ...
  4. Thanks to both of you for clearing up so many...

    Thanks to both of you for clearing up so many things! did not know a lot of this. I will do as you recomended and use getopt() for my little project as it seems to provide me with exactly what I was...
  5. That worked nicely, but why exactly is it...

    That worked nicely, but why exactly is it considered bad form if it works? I can see why single letter variable names like l are frowned upon as rags_to_riches pointed out, but not sure if I got what...
  6. Thanks a lot guys! I am used to it being a space...

    Thanks a lot guys! I am used to it being a space between the argument and the string, but now I see. Out of curiosity, how would one add a space between '-s' and the string without getting an error? ...
  7. Need help understanding a piece of code

    Hi,

    I came across an example program for command line arguments in C and it contains a piece of code I can't get my head around. The following is the program:


    #include <stdio.h>
    #include...
Results 1 to 7 of 7