]> granicus.if.org Git - php/commitdiff
- Fix allocation size
authorFelipe Pena <felipensp@gmail.com>
Tue, 12 Nov 2013 15:17:24 +0000 (13:17 -0200)
committerFelipe Pena <felipensp@gmail.com>
Tue, 12 Nov 2013 15:17:24 +0000 (13:17 -0200)
phpdbg_utils.c

index 4ad75acd1047645ddfae4e66ed7f865cc11e4f3a..e8a5dc634700f99be7f669a09292abd329713bc0 100644 (file)
@@ -19,7 +19,7 @@
 
 #include <stdio.h>
 #include <ctype.h>
-#include "zend_alloc.h"
+#include "zend.h"
 #include "phpdbg_utils.h"
 
 int phpdbg_is_numeric(const char *str) /* {{{ */
@@ -60,7 +60,7 @@ int phpdbg_is_class_method(const char *str, size_t len, char **class, char **met
        *class = estrndup(str, sep - str);
        class[sep - str] = 0;
 
-       *method = estrndup(sep+2, str + len - sep);
+       *method = estrndup(sep+2, str + len - (sep + 2));
 
        return 1;
 } /* }}} */