fix netbuf_getbytes not detecting EOF in some cases webdav

Mon, 02 May 2022 20:37:13 +0200

author
Olaf Wintermann <olaf.wintermann@gmail.com>
date
Mon, 02 May 2022 20:37:13 +0200
branch
webdav
changeset 330
71b652743871
parent 329
d2b2124801f4
child 331
ab26980faad6

fix netbuf_getbytes not detecting EOF in some cases

src/server/util/netbuf.c file | annotate | diff | comparison | revisions
--- a/src/server/util/netbuf.c	Mon May 02 20:26:54 2022 +0200
+++ b/src/server/util/netbuf.c	Mon May 02 20:37:13 2022 +0200
@@ -141,6 +141,8 @@
 
             buf->pos += bytes_in_buffer;
             return bytes_in_buffer;
+        } else if(buf->pos >= buf->maxsize) {
+            return NETBUF_EOF;
         }
     }
     

mercurial