Welcome to the forums and to C++ programming!
I assume by "declared twice" (constructs such as for loops aren't "declared" by the way) you're referring to this nesting of loops?
This is...
Type: Posts; User: PehJota
Welcome to the forums and to C++ programming!
I assume by "declared twice" (constructs such as for loops aren't "declared" by the way) you're referring to this nesting of loops?
This is...
This sounds like a message from `make`. Look in your project's directory/ies. Do you see a file named 'Makefile' anywhere? If so, could you please post its contents?
If I understand your question right, you'll want to change this line:
{"listen_port", required_argument, &listen_port_switch, 1},
to something like:
{"listen_port", required_argument, NULL,...
You ran over your driving instructors dog, run the test again and you should pass, he doesn't have a dog any more[/QUOTE]
vBulletin needs a "like" button. :D
To the OP: Your code is wide open...
Additional little nit pick: using the modulo operator to shrink the range of rand() is okay for a simple program where uniformity is of no concern, but the results of such randomization are skewed....
Right, the 'afternoon' in main() is not initialized. I think you meant to use 'char&' instead of 'char' on the parameter list for convert() (then convert() would initialize 'afternoon' for you). You...
I see this thread is almost a week old, but since the OP may still have this problem and others may find this in a future search I hope no one blames me for necroposting here.
I think your problem...
Yes, that was my problem. I fixed that, and now my code is working on GNU/Linux, SunOS, and MS Windows. Thanks!
I'm getting a value from errno in my server_error() function, and no other...
Thanks for the heads up on that behavior of sendto with buffers; time-permitting, I'll look into that myself and throw in a workaround for that.
But on my GNU/Linux system, sendto() fails on the...
I'm writing a simple UDP server, and right now as placeholder code I'm simply echoing back input. But sendto() is returning -1 and failing to send. On Debian GNU/Linux with GCC 4.4, this happens once...
That server is responding now, apparently.
To simply compile, run:
$ gcc -Wall -o hello_world hello_world.c
("$" is the shell prompt; don't type it.) "-Wall" tells GCC to output all warnings,...