|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #25428 xmlrpc_server_call_method() causes segfault
Submitted: 2003-09-08 03:38 UTC Modified: 2005-01-26 04:44 UTC
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: mfladischer at gmx dot net Assigned:
Status: Closed Package: XMLRPC-EPI related
PHP Version: 5.0.0 OS: Windows XP
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: mfladischer at gmx dot net
New email:
PHP Version: OS:


 [2003-09-08 03:38 UTC] mfladischer at gmx dot net
When i'm trying to run a XML-RPC server  (using the xml-rpc-extension) with PHP5 i get a segfault.

Reproduce code:
$request = xmlrpc_encode_request("system.listMethods", array());
$server = xmlrpc_server_create();
echo xmlrpc_server_call_method($server, $request, false);

Expected result:
<?xml version="1.0" encoding="iso-8859-1"?>

Actual result:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 19945)]
0x0822d92f in zif_xmlrpc_server_call_method (ht=3, return_value=0x408ef0ac, this_ptr=0x0, return_value_used=1)
    at /linux/devel/php5/ext/xmlrpc/xmlrpc-epi-php.c:1033
1033            set_output_options(&out, *output_opts);
(gdb) bt
#0  0x0822d92f in zif_xmlrpc_server_call_method (ht=3, return_value=0x408ef0ac, this_ptr=0x0, return_value_used=1)
    at /linux/devel/php5/ext/xmlrpc/xmlrpc-epi-php.c:1033
#1  0x082a2583 in zend_do_fcall_common_helper (execute_data=0xbfffd180, op_array=0x408ee410) at /linux/devel/php5/Zend/zend_execute.c:2541
#2  0x082a2d25 in zend_do_fcall_handler (execute_data=0xbfffd180, op_array=0x408ee410) at /linux/devel/php5/Zend/zend_execute.c:2687
#3  0x0829e834 in execute (op_array=0x408ee410) at /linux/devel/php5/Zend/zend_execute.c:1267
#4  0x0827f0f7 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at /linux/devel/php5/Zend/zend.c:1018
#5  0x0823f15c in php_execute_script (primary_file=0xbffff580) at /linux/devel/php5/main/main.c:1625
#6  0x082acea7 in main (argc=2, argv=0xbffff614) at /linux/devel/php5/sapi/cli/php_cli.c:910
#7  0x40767bf7 in __libc_start_main () from /lib/i686/


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-10-14 20:09 UTC] web-php-bugs at sklar dot com
This diff against v1.35 of ext/xmlrpc/xmlrpc-epi.php.c fixes the problem.

diff -r1.35 xmlrpc-epi-php.c
<       set_output_options(&out, *output_opts);
>       if (argc == 3) {
>         set_output_options(&out, NULL);
>     } else {
>         set_output_options(&out, *output_opts);
>     }
 [2003-10-14 20:16 UTC]
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at
In case this was a documentation problem, the fix will show up soon at

In case this was a website problem, the change will show
up on the site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.

Patch applied.
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Apr 11 16:01:23 2021 UTC