summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/json/json.c2
-rw-r--r--ext/json/json_encoder.c4
2 files changed, 4 insertions, 2 deletions
diff --git a/ext/json/json.c b/ext/json/json.c
index 8042f70d23..f59daceda1 100644
--- a/ext/json/json.c
+++ b/ext/json/json.c
@@ -38,8 +38,6 @@ static PHP_FUNCTION(json_decode);
static PHP_FUNCTION(json_last_error);
static PHP_FUNCTION(json_last_error_msg);
-static const char digits[] = "0123456789abcdef";
-
PHP_JSON_API zend_class_entry *php_json_serializable_ce;
ZEND_DECLARE_MODULE_GLOBALS(json)
diff --git a/ext/json/json_encoder.c b/ext/json/json_encoder.c
index d501a6619c..6976d906c0 100644
--- a/ext/json/json_encoder.c
+++ b/ext/json/json_encoder.c
@@ -30,6 +30,10 @@
#include "php_json.h"
#include <zend_exceptions.h>
+ZEND_DECLARE_MODULE_GLOBALS(json)
+
+static const char digits[] = "0123456789abcdef";
+
static void json_escape_string(smart_str *buf, char *s, size_t len, int options TSRMLS_DC);
static int json_determine_array_type(zval *val TSRMLS_DC) /* {{{ */