Explorar el Código

Fixed response cleanup regression introduced by e264d9ec9ef98e6f26f5f547ec941927a35ffa56

Evgeny Grin (Karlson2k) hace 8 años
padre
commit
28ca871401
Se han modificado 1 ficheros con 5 adiciones y 1 borrados
  1. 5 1
      src/microhttpd/connection.c

+ 5 - 1
src/microhttpd/connection.c

@@ -3175,7 +3175,11 @@ MHD_connection_handle_idle (struct MHD_Connection *connection)
                 }
               /* Response is not required anymore for this connection. */
               if (NULL != connection->response)
-                MHD_destroy_response (connection->response);
+                {
+                  struct MHD_Response const *resp = connection->response;
+                  connection->response = NULL;
+                  MHD_destroy_response (resp);
+                }
               continue;
             }
 #endif /* UPGRADE_SUPPORT */