Annotation of embedaddon/php/ext/xmlrpc/tests/bug45555.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: Bug #45555 (Segfault with invalid non-string as register_introspection_callback)
        !             3: --SKIPIF--
        !             4: <?php if (!extension_loaded("xmlrpc")) print "skip"; ?>
        !             5: --FILE--
        !             6: <?php
        !             7: 
        !             8: $options = array ();
        !             9: $request = xmlrpc_encode_request ("system.describeMethods", $options);
        !            10: $server = xmlrpc_server_create ();
        !            11: 
        !            12: xmlrpc_server_register_introspection_callback($server, 1);
        !            13: xmlrpc_server_register_introspection_callback($server, array('foo', 'bar'));
        !            14: 
        !            15: $options = array ('output_type' => 'xml', 'version' => 'xmlrpc');
        !            16: xmlrpc_server_call_method ($server, $request, NULL, $options);
        !            17: 
        !            18: ?>
        !            19: --EXPECTF--
        !            20: Warning: xmlrpc_server_call_method(): Invalid callback '1' passed in %s on line %d
        !            21: 
        !            22: Warning: xmlrpc_server_call_method(): Invalid callback 'foo::bar' passed in %s on line %d

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>