--- bla/libmicrohttpd/src/microhttpd/digestauth.c 2015-05-29 12:20:53.027686000 +0200 +++ digestauth.c 2015-06-04 13:11:08.123697504 +0200 @@ -508,7 +508,10 @@ connection, argp); if (MHD_YES != test_header (connection, argp, NULL)) - return MHD_NO; + { + free(argb); + return MHD_NO; + } num_headers++; break; } @@ -527,10 +530,16 @@ connection, equals); if (! test_header (connection, argp, equals)) - return MHD_NO; + { + free(argb); + return MHD_NO; + } + num_headers++; argp = amper; } + + free(argb); /* also check that the number of headers matches */ for (pos = connection->headers_received; NULL != pos; pos = pos->next)