Language
Compiler
Options
$
&foo.data=0x7ffd5167d330
&bar.data=0x7ffd5167d330
foo_data =0
Signal:
Segmentation fault
Author
anonymous
about 8 years ago
Author
anonymous
about 8 years ago
$
prog.cc: In function 'int* Foo()':
prog.cc:12:10: warning: address of local variable 'foo' returned [-Wreturn-local-addr]
Data foo=1000;
^
prog.cc: In function 'int* Bar()':
prog.cc:19:10: warning: address of local variable 'bar' returned [-Wreturn-local-addr]
Data bar=2000;
^
&foo.data=0x7ffd5167d330
&bar.data=0x7ffd5167d330
foo_data =0