diff options
author | 2013-12-11 14:57:54 -0500 | |
---|---|---|
committer | 2013-12-11 14:57:54 -0500 | |
commit | 001407495e8ce63fcff702515db38b882d425da8 (patch) | |
tree | 00c51911af9b45c7c29ef1ba89f02a3d49f0fd69 /src/c/http.c | |
parent | 56c340c258a706fec1186297649c5cedf64d2e3e (diff) |
Fix regression in http.c for long-polling connections; add lazy initialization of database connections, to avoid the overhead in handlers that don't use SQL
Diffstat (limited to 'src/c/http.c')
-rw-r--r-- | src/c/http.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/c/http.c b/src/c/http.c index 5ceca059..d19ce350 100644 --- a/src/c/http.c +++ b/src/c/http.c @@ -260,7 +260,9 @@ static void *worker(void *data) { close(sock); sock = 0; } - } else if (rr != KEEP_OPEN) + } else if (rr == KEEP_OPEN) + sock = 0; + else fprintf(stderr, "Illegal uw_request return code: %d\n", rr); break; |