[Bug libstdc++/16612] empty basic_strings can't live in shared memory

2006-12-13 Thread choe dot hwanjin at gmail dot com


--- Comment #31 from choe dot hwanjin at gmail dot com  2006-12-14 07:29 
---
Created an attachment (id=12801)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12801&action=view)
basic_string test code with visibility option

Something similar happens when I use GCC option -fvisibility=hidden.

I made a DSO which uses basic_string<>.
And the main function created a basic_string instance with default constructor.
It called a function of the DSO with the basic_string reference in main
function.
Inside the DSO,  the function assigned new string to the reference. Then
it crashes.

I made a simple test code.

For test follow this step:
tar xzf stringtest.tar.gz
cd stringtest
make
./test

then it will be abort with an error.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16612



[Bug libstdc++/16612] empty basic_strings can't live in shared memory

2006-12-13 Thread choe dot hwanjin at gmail dot com


--- Comment #32 from choe dot hwanjin at gmail dot com  2006-12-14 07:30 
---
(From update of attachment 12801)
Something similar happens when I use GCC option -fvisibility=hidden.

I made a DSO which uses basic_string<>.
And the main function created a basic_string instance with default constructor.
It called a function of the DSO with the basic_string reference in main
function.
Inside the DSO,  the function assigned new string to the reference. Then
it crashes.

I made a simple test code.

For test follow this step:
tar xzf stringtest.tar.gz
cd stringtest
make
./test

then it will be abort with an error.

I tested it on Debian unstable, GCC 4.0.3.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16612