summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
6f34d13)
http://code.google.com/p/disorder/issues/detail?id=24
/* probably the reader has stopped listening for some reason */
if(write(sigfd[s], &sc, 1) < 0) {
/* probably the reader has stopped listening for some reason */
if(write(sigfd[s], &sc, 1) < 0) {
- write(2, errmsg, sizeof errmsg - 1);
+ /* do the best we can as we're about to abort; shut _up_, gcc */
+ int _ignore = write(2, errmsg, sizeof errmsg - 1);
+ (void)_ignore;
|| write(sfd, q->id, l) < 0)
fatal(errno, "writing to %s", addr.sun_path);
/* Await the ack */
|| write(sfd, q->id, l) < 0)
fatal(errno, "writing to %s", addr.sun_path);
/* Await the ack */
+ if (read(sfd, &l, 1) < 0)
+ fatal(errno, "reading ack from %s", addr.sun_path);
/* Plumbing */
xdup2(np[0], 0);
xdup2(sfd, 1);
/* Plumbing */
xdup2(np[0], 0);
xdup2(sfd, 1);
id[l] = 0;
D(("id %s fd %d", id, fd));
t = findtrack(id, 1/*create*/);
id[l] = 0;
D(("id %s fd %d", id, fd));
t = findtrack(id, 1/*create*/);
- write(fd, "", 1); /* write an ack */
+ if (write(fd, "", 1) < 0) /* write an ack */
+ error(errno, "writing ack to inbound connection");
if(t->fd != -1) {
error(0, "%s: already got a connection", id);
xclose(fd);
if(t->fd != -1) {
error(0, "%s: already got a connection", id);
xclose(fd);