Skip to content

Commit

Permalink
fix silly bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen Tu committed Aug 13, 2013
1 parent 37fc1ed commit 94db0b4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion fileutils.h
Expand Up @@ -27,7 +27,7 @@ class fileutils {
if (r == 0) if (r == 0)
return EOF; return EOF;
if (r < 0) { if (r < 0) {
if (!(errno == EAGAIN || errno == EWOULDBLOCK || errno == EINTR)) if (errno == EAGAIN || errno == EWOULDBLOCK || errno == EINTR)
continue; continue;
return r; return r;
} }
Expand Down
2 changes: 1 addition & 1 deletion stats_server.cc
Expand Up @@ -43,7 +43,7 @@ stats_server::serve_forever()
int cfd = accept(fd, nullptr, 0); int cfd = accept(fd, nullptr, 0);
if (cfd < 0) if (cfd < 0)
throw system_error(errno, system_category(), "accept failed"); throw system_error(errno, system_category(), "accept failed");
thread(&stats_server::serve_client, this, fd).detach(); thread(&stats_server::serve_client, this, cfd).detach();
} }
} }


Expand Down

0 comments on commit 94db0b4

Please sign in to comment.