summaryrefslogtreecommitdiff
path: root/ext/json/json.c
diff options
context:
space:
mode:
authorMáté Kocsis <kocsismate@woohoolabs.com>2020-04-01 23:32:39 +0200
committerMáté Kocsis <kocsismate@woohoolabs.com>2020-04-06 10:41:01 +0200
commit50765075db6b6d5a9597589601c59f743f6ee9c8 (patch)
tree29ef6350004c95c3df9577e47ceaa1458e60921e /ext/json/json.c
parent21cfa03f1740042d0c48269430e0490e319e1408 (diff)
downloadphp-git-50765075db6b6d5a9597589601c59f743f6ee9c8.tar.gz
Improve some ValueError messages
Closes GH-5340
Diffstat (limited to 'ext/json/json.c')
-rw-r--r--ext/json/json.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/json/json.c b/ext/json/json.c
index b78de3ea16..c64378fd56 100644
--- a/ext/json/json.c
+++ b/ext/json/json.c
@@ -299,12 +299,12 @@ PHP_FUNCTION(json_decode)
}
if (depth <= 0) {
- zend_value_error("Depth must be greater than zero");
+ zend_argument_value_error(3, "must be greater than 0");
RETURN_THROWS();
}
if (depth > INT_MAX) {
- zend_value_error("Depth must be lower than %d", INT_MAX);
+ zend_argument_value_error(3, "must be less than %d", INT_MAX);
RETURN_THROWS();
}