Created attachment 522214 [details]
Tarfile of test case
Description of problem:
I'm working on a gsoap application and my application is SEGfaulting during exit. I worked to get a testcase down to the minimal amount to show the issue. I've attached everything you need to work the problem and show the issue.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. untar the attached test sources
2. gcc -g -o test-gsoap test-gsoap.c -lgsoapssl -lssl
3. run test-gsoap and see the SEGV
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
#0 0x0000000000000000 in ?? ()
#1 0x0000000000606030 in ?? ()
#2 0x00007fffffffe228 in ?? ()
#3 0x0000000000000000 in ?? ()
Code shouldn't segfault.
The test code attached is a minimal app to show the issue.
When using the gsoap libraries you must use the same CFLAGS that where used when the libraries were compiled. The preferred way to do this is to use pkg-config. In your example you are using the gsoapssl library. For correct operation you should then compile your code with `pkg-config --cflags gsoapssl`.
When I do this I do not get a segfault with your test code:
$ gcc -g `pkg-config --cflags gsoapssl` -o test-gsoap test-gsoap.c -lgsoapssl -lssl
If I leave out the pkg-config part I can reproduce your error.