When I pass an undef (or "", maybe) to Apache::Util->unescape_uri_info 
it gives me segfault.
Any idea?

Kenneth


--------- PerlHandler ---------
package Apache::SegFault;
use Apache::Util qw(unescape_uri_info);

sub handler
{
    my ($r) = shift;
    $r->send_http_header("text/html");
    print "<h1>I'll give you segfault ;-)</h1>\n";
    print unescape_uri_info(scalar $r->args);
    OK;
}

1;

--------- Backtrace ---------
[root@devel root]# gdb /www/bin/httpd
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux"...(no debugging symbols
found)...
(gdb) run -X -f /www/conf/httpd.conf -d /tmp
Starting program: /www/bin/httpd -X -f /www/conf/httpd.conf -d /tmp
defined(@array) is deprecated at /usr/lib/perl5/site_perl/5.6.0/Apache/DBI.pm
line 135.
        (Maybe you should just omit the defined()?)
(no debugging symbols found)...
Program received signal SIGSEGV, Segmentation fault.
0x8091b30 in XS_Apache_unescape_url_info ()
(gdb) bt
#0  0x8091b30 in XS_Apache_unescape_url_info ()
#1  0x816c355 in Perl_pp_entersub ()
#2  0x81673ed in Perl_runops_standard ()
#3  0x812f475 in perl_call_sv ()
#4  0x812f23e in perl_call_sv ()
#5  0x808ae8b in perl_call_handler ()
#6  0x808a846 in perl_run_stacked_handlers ()
#7  0x808959d in perl_handler ()
#8  0x80ec7f3 in ap_invoke_handler ()
#9  0x80ffe09 in ap_some_auth_required ()
#10 0x80ffe6c in ap_process_request ()
#11 0x80f770e in ap_child_terminate ()
#12 0x80f789c in ap_child_terminate ()
#13 0x80f79f9 in ap_child_terminate ()
#14 0x80f8026 in ap_child_terminate ()
#15 0x80f87b3 in main ()
#16 0x406501eb in __libc_start_main (main=0x80f846c <main>, argc=6,
argv=0xbffffbb4, 
    init=0x806e7c8 <_init>, fini=0x81a484c <_fini>, rtld_fini=0x4000a610
<_dl_fini>, 
    stack_end=0xbffffbac) at ../sysdeps/generic/libc-start.c:90

Reply via email to