]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
core: ap_getline_core() reads nothing for n == 0.
authorYann Ylavic <ylavic@apache.org>
Tue, 20 Mar 2018 21:40:11 +0000 (21:40 +0000)
committerYann Ylavic <ylavic@apache.org>
Tue, 20 Mar 2018 21:40:11 +0000 (21:40 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1827362 13f79535-47bb-0310-9956-ffa450edef68

server/protocol.c

index 31101bd6edf3ea190ac6ea1ccd282399f1712d48..460bf00dd98a69fa2520b273e99578eab3d0c889 100644 (file)
@@ -227,6 +227,7 @@ AP_DECLARE(apr_status_t) ap_rgetline_core(char **s, apr_size_t n,
 
     if (!n) {
         /* Needs room for NUL byte at least */
+        *read = 0;
         return APR_BADARG;
     }