muthusuba / serf

Automatically exported from code.google.com/p/serf
Apache License 2.0
0 stars 0 forks source link

Serf 1.3.8: Segmentation fault in test_ssl_init #157

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Serf 1.3.7 still passes all tests.
Serf 1.3.8 fails. (I locally backported r2443 to allow test suite to even 
compile.)
`scons check` runs `build/check.py`, which runs `test/test_all`.

Output of `scons check` (not helpful):
...
== Running the unit tests ==
ERROR: test(s) failed in test_all
scons: *** [check] Error 1
scons: building terminated because of errors.

Manual running of `test/test_all` is more helpful:

$ test/test_all
Segmentation fault
$ gdb --args test/test_all
GNU gdb (Gentoo 7.8.1 vanilla) 7.8.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from test/test_all...done.
(gdb) r
Starting program: /tmp/serf-1.3.8/test/test_all 
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
serf_bucket_simple_create (data=data@entry=0x40fe10 "", len=len@entry=0, 
freefunc=freefunc@entry=0x0, freefunc_baton=freefunc_baton@entry=0x0, 
    allocator=allocator@entry=0x7ffff7f500b0) at buckets/simple_buckets.c:48
48          ctx->original = ctx->current = data;
(gdb) bt
#0  serf_bucket_simple_create (data=data@entry=0x40fe10 "", len=len@entry=0, 
freefunc=freefunc@entry=0x0, freefunc_baton=freefunc_baton@entry=0x0, 
    allocator=allocator@entry=0x7ffff7f500b0) at buckets/simple_buckets.c:48
#1  0x000000000040daf0 in test_ssl_init (tc=0x61dae0) at test/test_ssl.c:43
#2  0x0000000000404422 in CuTestRun (tc=tc@entry=0x61dae0) at test/CuTest.c:173
#3  0x0000000000404abc in CuSuiteRun (testSuite=testSuite@entry=0x618210) at 
test/CuTest.c:357
#4  0x0000000000403d0d in main (argc=<optimized out>, argv=<optimized out>) at 
test/test_all.c:95
(gdb) print ctx
$1 = (simple_context_t *) 0x0

I use Gentoo GNU/Linux, amd64, glibc 2.19, GCC 4.8.3, GNU binutils 2.24.90, APR 
1.6_pre, APR-Util 1.5.5_pre, OpenSSL 1.0.1j.

Original issue reported on code.google.com by Arfrever...@gmail.com on 5 Nov 2014 at 9:33

GoogleCodeExporter commented 9 years ago
I am wondering if this also happens with r2445 backported?

Original comment by andreas.stieger@gmx.de on 5 Nov 2014 at 11:12

GoogleCodeExporter commented 9 years ago
Apparently backportation of r2445 helps in 1.3.x branch.
(Test suite in trunk fails in a different way. Issue #158.)

Original comment by Arfrever...@gmail.com on 5 Nov 2014 at 1:24

GoogleCodeExporter commented 9 years ago
See also https://groups.google.com/forum/#!msg/serf-dev/qoTK8BfRfrI/EJL7xj4PmT4J
Fixed in trunk, should be backported. Closing.

Original comment by andreas.stieger@gmx.de on 5 Nov 2014 at 1:40