Quote Originally Posted by ChrisW67 View Post
Apart from the main window destructor derefrencing an uninitialised pointer the code as presented compiles and runs fine here.
Qt Code:
  1. chrisw@newton /tmp/simple_example $ ./simple_example
  2. Listening
  3. Incoming connection
  4. Incoming connection
  5. Incoming connection
  6. Incoming connection
  7. Destruction
  8. Segmentation fault
To copy to clipboard, switch view to plain text mode 
I was using telnet to connect to port 5600 from two separate places.

Start by correcting the destructor, clean the build, run qmake, and rebuild.
I got it working somehow, but I'm redoing my approach so I can share a QList between classes (I need to keep track of connections). So, I'm going to make a new thread in a bit if I can't figure it out. In my other program (C), I used 'extern' to share the struct between files, let's hope Qt acts the same.