]> prime8.dev >> repos - ttyd.git/commitdiff
http: fix keepalive for lws_serve_http_file
authorShuanglei Tao <tsl0922@gmail.com>
Sat, 22 Jun 2019 07:22:53 +0000 (15:22 +0800)
committerShuanglei Tao <tsl0922@gmail.com>
Sat, 22 Jun 2019 07:23:24 +0000 (15:23 +0800)
src/http.c

index e5d702614da3672efecbb004eed4c15d393dbd7f..38a94e3c4b77f6fe6dd6ec1b5fa5d8a7a083ff40 100644 (file)
@@ -155,6 +155,9 @@ callback_http(struct lws *wsi, enum lws_callback_reasons reason, void *user, voi
             lws_callback_on_writable(wsi);
             break;
 
+        case LWS_CALLBACK_HTTP_FILE_COMPLETION:
+            goto try_to_reuse;
+
         case LWS_CALLBACK_OPENSSL_PERFORM_CLIENT_CERT_VERIFICATION:
             if (!len || (SSL_get_verify_result((SSL *) in) != X509_V_OK)) {
                 int err = X509_STORE_CTX_get_error((X509_STORE_CTX *) user);