[Interest] proper (silent) exit in response to SIGHUP - and signal/slot serialisation?

René J.V. Bertin rjvbertin at gmail.com
Fri Oct 19 16:54:06 CEST 2018


On Friday October 19 2018 16:11:34 Jason H wrote:
> There are two ways:
> By direct invocation (same thread only)
> Or 
> By inserting an event into an event loop of the appropriate thread (same or different thread).  
> Queued connection just ensures that if direction invocation is available, that it is not used. I've only ever had to use this once in my life.

Thanks.

I think I was doing something wrong on a different level. I didn't read (in my graceful exit proc) from the pipe to which I had written in order to trigger the QSocketNotifier. 

Curiously I also discovered a bit later that QSocketNotifier apparently reacts to unread data on the fd/socket instead of only once to the writing of that data (Linux 4.14, Qt 5.9.6): my slot was being called repetitively in reaction to a single signal. Probably after modifying something because this does seem to contradict what I noticed earlier...

Anyway, now that I read from the pipe when the slot is called everything seems to work as intended again...



More information about the Interest mailing list