aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-08-08 05:24:57 +0000
committerChristian Grothoff <christian@grothoff.org>2013-08-08 05:24:57 +0000
commit37c1aa3fcf1df820ad105c4f80da4f96913d2367 (patch)
tree0c591cbe257bdcfbefc771664b2cef9e2c07525f
parent22941cd1b63afa6db6f6b71028f2a30be8fb1b5c (diff)
downloadlibmicrohttpd-37c1aa3fcf1df820ad105c4f80da4f96913d2367.tar.gz
libmicrohttpd-37c1aa3fcf1df820ad105c4f80da4f96913d2367.zip
-handle method being NULL
-rw-r--r--src/microhttpd/connection.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index e198b6cd..6529e53b 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -547,7 +547,8 @@ add_extra_headers (struct MHD_Connection *connection)
547 /* if not present, add content length */ 547 /* if not present, add content length */
548 if ( (NULL == MHD_get_response_header (connection->response, 548 if ( (NULL == MHD_get_response_header (connection->response,
549 MHD_HTTP_HEADER_CONTENT_LENGTH)) && 549 MHD_HTTP_HEADER_CONTENT_LENGTH)) &&
550 ( (0 != strcasecmp (connection->method, 550 ( (NULL == connection->method) ||
551 (0 != strcasecmp (connection->method,
551 MHD_HTTP_METHOD_CONNECT)) || 552 MHD_HTTP_METHOD_CONNECT)) ||
552 (0 != connection->response->total_size) ) ) 553 (0 != connection->response->total_size) ) )
553 { 554 {