summaryrefslogtreecommitdiff
path: root/ext/standard/base64.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/standard/base64.c')
-rw-r--r--ext/standard/base64.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/ext/standard/base64.c b/ext/standard/base64.c
index 0a4093f185..fd1c910234 100644
--- a/ext/standard/base64.c
+++ b/ext/standard/base64.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -59,10 +59,6 @@ PHPAPI zend_string *php_base64_encode(const unsigned char *str, size_t length) /
unsigned char *p;
zend_string *result;
- if (length < 0) {
- return NULL;
- }
-
result = zend_string_alloc(((length + 2) / 3) * 4 * sizeof(char), 0);
p = (unsigned char *)result->val;