Re: Segmentation fault with unique_ptr

2015-02-13 Thread tassos_souris
the main function is as simple as this: Compile with: g++-4.9 -std=c++14 -g -o main main.cpp and run with ./main. I get segfault. gdb in bt shows that the segfault happens inside unique_ptr destructor. So it is not a memory issue. Also since the code runs with less size (i.e size=1000 no proble

Re: Segmentation fault with unique_ptr

2015-02-13 Thread Kyrill Tkachov
On 13/02/15 11:15, tassos_souris wrote: Hi to everyone, I am using g++-4.9 with -std=c++14 option (no optimization flag). For some reason i have the following singly_linked_list class. The usage is this: 1) Construct a singly linked list 2) push_front() at least 1 values (this is import

Segmentation fault with unique_ptr

2015-02-13 Thread tassos_souris
Hi to everyone, I am using g++-4.9 with -std=c++14 option (no optimization flag). For some reason i have the following singly_linked_list class. The usage is this: 1) Construct a singly linked list 2) push_front() at least 1 values (this is important -- i.e for 1000 values i don't get a se