Status: New
Owner: liuj...@google.com
Labels: Type-Defect Priority-Medium

New issue 672 by leoxiang...@gmail.com: FileDescriptorTables double free problem when use protobuf both in shared library and in main.cpp
https://code.google.com/p/protobuf/issues/detail?id=672

What steps will reproduce the problem?
1. compile *.pb.cpp file with main.cpp to generate executable
2. compile *.pb.cpp file witeh other.cpp to generate a shared library test.so
3. dlopen test.so in main.cpp and call the function in shared library
4. when process end, there will be a double free corruption catched.

What is the expected output? What do you see instead?
hello in so
*** glibc detected *** ./main: double free or corruption (!prev): 0x000000000097e850 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x7ec66)[0x7f2e9d1d7c66]
./main[0x4479de]
./main[0x42cc1b]
./main[0x42b628]
./main[0x42a5db]
./main[0x429935]
./main[0x41370c]
./main[0x413726]
./main[0x413740]
./main(_ZN6google8protobuf20FileDescriptorTablesD1Ev+0x31)[0x41389b]
/lib/x86_64-linux-gnu/libc.so.6(+0x3b9d1)[0x7f2e9d1949d1]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ba55)[0x7f2e9d194a55]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf4)[0x7f2e9d17a794]
./main[0x4070c9]
======= Memory map: ========


What version of the product are you using? On what operating system?
protobuf 2.5 on Linux ubuntu 3.11.0-15-generic


Please provide any additional information below.
it seems something wrong with the deconstruction with FileDescriptorTables

Attachments:
        main.cpp  1.2 KB
        Makefile  900 bytes
        so.so  2.9 MB
        poker_config.pb.cpp  13.6 KB
        poker_config.pb.h  7.6 KB

--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups "Protocol 
Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To post to this group, send email to protobuf@googlegroups.com.
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/d/optout.

Reply via email to