Permalink
Browse files

Make conn reader loop a bit clearer

  • Loading branch information...
1 parent 5d5a961 commit 3edff59179d804baae88a1bd27f41473f435e3c2 @garlick garlick committed May 14, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 libnpfs/conn.c
View
@@ -163,14 +163,14 @@ np_conn_read_proc(void *a)
pthread_detach(pthread_self());
- while (conn->trans) {
+ for (;;) {
if (np_trans_recv(conn->trans, &fc, conn->msize) < 0) {
np_logerr (srv, "recv error - "
"dropping connection to '%s'",
conn->client_id);
break;
}
- if (!fc)
+ if (!fc) /* EOF */
break;
_debug_trace (srv, fc);

0 comments on commit 3edff59

Please sign in to comment.