]> granicus.if.org Git - php/commitdiff
Use the portable zend_strndup() instead of strndup()
authorChristoph M. Becker <cmbecker69@gmx.de>
Fri, 28 Jun 2019 08:20:50 +0000 (10:20 +0200)
committerChristoph M. Becker <cmbecker69@gmx.de>
Fri, 28 Jun 2019 08:23:38 +0000 (10:23 +0200)
sapi/phpdbg/phpdbg.c

index 4a8ab1c5a49d2bc120f6d751cb122aad385b0d38..eca24b4a4dc97f5974cec562c6a2fda2172f1253 100644 (file)
@@ -311,7 +311,7 @@ static PHP_FUNCTION(phpdbg_exec)
                                        result = 0;
                                }
 
-                               PHPDBG_G(exec) = strndup(ZSTR_VAL(exec), ZSTR_LEN(exec));
+                               PHPDBG_G(exec) = zend_strndup(ZSTR_VAL(exec), ZSTR_LEN(exec));
                                PHPDBG_G(exec_len) = ZSTR_LEN(exec);
 
                                if (result) {