Browse Source

[multiple] minor: remove duplicated conditions

x-ref:
  "PVS-Studio Analysis Results"
  https://redmine.lighttpd.net/boards/3/topics/8459
  http://www.fly-server.ru/pvs-studio/lighttpd/
personal/stbuehler/fix-fdevent
Glenn Strauss 3 years ago
parent
commit
859c9ae586
  1. 5
      src/mod_cgi.c
  2. 2
      src/mod_wstunnel.c

5
src/mod_cgi.c

@ -620,10 +620,7 @@ static ssize_t cgi_write_file_chunk_mmap(server *srv, connection *con, int fd, c
}
}
if (r >= 0) {
chunkqueue_mark_written(cq, r);
}
chunkqueue_mark_written(cq, r);
return r;
}

2
src/mod_wstunnel.c

@ -884,7 +884,7 @@ handler_t mod_wstunnel_handshake_create_response(handler_ctx *hctx) {
/* 8 bytes should have been sent with request
* for draft-ietf-hybi-thewebsocketprotocol-00 */
chunkqueue *cq = con->request_content_queue;
if (0 == hctx->hybivers && chunkqueue_length(cq) < 8)
if (chunkqueue_length(cq) < 8)
return HANDLER_WAIT_FOR_EVENT;
#endif /* _MOD_WEBSOCKET_SPEC_IETF_00_ */

Loading…
Cancel
Save