From e0754d1638c602382384f1eface30854b1defeec Mon Sep 17 00:00:00 2001
From: Christian Grothoff <christian@grothoff.org>
Date: Sun, 26 Feb 2023 17:51:24 +0100
Subject: fix parser bug that could be used to crash servers using the
 MHD_PostProcessor

---
 src/microhttpd/postprocessor.c |  2 +-
 1 file changed, 1 insertions(+), 1 deletions(-)

Index: libmicrohttpd-0.9.72/src/microhttpd/postprocessor.c
===================================================================
--- libmicrohttpd-0.9.72.orig/src/microhttpd/postprocessor.c	2023-03-29 19:22:08.888629726 +0200
+++ libmicrohttpd-0.9.72/src/microhttpd/postprocessor.c	2023-03-29 19:22:08.884629728 +0200
@@ -321,7 +321,7 @@
       return NULL; /* failed to determine boundary */
     boundary += MHD_STATICSTR_LEN_ ("boundary=");
     blen = strlen (boundary);
-    if ( (blen == 0) ||
+    if ( (blen < 2) ||
          (blen * 2 + 2 > buffer_size) )
       return NULL;              /* (will be) out of memory or invalid boundary */
     if ( (boundary[0] == '"') &&
