|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #33502 Some nullary functions don't check the number of arguments
Submitted: 2005-06-28 21:44 UTC Modified: 2018-07-12 13:01 UTC
From: bah at xpto dot org Assigned: cmb (profile)
Status: Closed Package: *General Issues
PHP Version: 7.3Git-2018-07-12 (Git) OS: *
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: bah at xpto dot org
New email:
PHP Version: OS:


 [2005-06-28 21:44 UTC] bah at xpto dot org
Index: output.c
RCS file: /repository/php-src/main/output.c,v
retrieving revision 1.166
diff -u -r1.166 output.c
--- output.c    28 Apr 2005 14:20:28 -0000      1.166
+++ output.c    28 Jun 2005 19:41:33 -0000
@@ -1042,6 +1042,10 @@
    Reset(clear) URL rewriter values */
+       if (ZEND_NUM_ARGS() != 0) {
+               ZEND_WRONG_PARAM_COUNT();
+       }
        if (php_url_scanner_reset_vars(TSRMLS_C) == SUCCESS) {
        } else {


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-12-30 22:57 UTC]
-Package: Feature/Change Request +Package: Output Control
 [2018-07-12 13:01 UTC]
-Summary: output_reset_rewrite_vars doesnt check the number of parameters +Summary: Some nullary functions don't check the number of arguments -Status: Open +Status: Verified -Type: Feature/Change Request +Type: Bug -Package: Output Control +Package: *General Issues -Operating System: n/a +Operating System: * -PHP Version: 5CVS-2005-06-28 (dev) +PHP Version: 7.3Git-2018-07-12 (Git) -Assigned To: +Assigned To: cmb
 [2018-07-12 13:01 UTC]
We had some discussion about this issue on the internals mailing
list[1], and have decided to treat this as bug, but for BC reasons
to apply the fix the master only.

Besides output_reset_rewrite_vars(), the following functions are
also affected:

* func_num_args()
* gc_status()
* gc_disable()
* gc_enable()
* gc_enabled()
* gc_collect_cycles()
* gc_mem_caches()
* zend_version()

[1] <>
 [2018-07-12 13:07 UTC]
Automatic comment on behalf of
Log: Fix #33502: Some nullary functions don't check the number of arguments
 [2018-07-12 13:07 UTC]
-Status: Verified +Status: Closed
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Wed Apr 21 20:01:24 2021 UTC