You can't do it like that (because the order of function argument evaluation is unspecified).
Instead, try this:
int err = fsync(rr->sock);
printf("%i %i - %s\n", err, errno, strerror(errno));...
Type: Posts; User: oogabooga
You can't do it like that (because the order of function argument evaluation is unspecified).
Instead, try this:
int err = fsync(rr->sock);
printf("%i %i - %s\n", err, errno, strerror(errno));...
Try putting an fsync call after your send call:
send(rr->sock, "text", 4, 0);
fsync(rr->sock);
You should, of course, be checking the return values for an error condition.
EDIT: I should...