[Qt-creator] Ignoring SIGPIPE when debugging with Creator on Mac
Adam Light
aclight at gmail.com
Fri May 15 23:17:58 CEST 2015
I'm using Qt Creator 3.4.0 on OSX 10.9 with Xcode 6.2 (and the
corresponding version of the command line developer tools).
My application is using a 3rd party closed source library that happens to
send a SIGPIPE signal in certain circumstances. When this happens and I am
running my application in the debugger (lldb) using Qt Creator, the
debugger breaks. I can continue, but the break is annoying.
I found a solution for this mentioned at
https://plus.google.com/113241179738681655641/posts/BmMiY8mpsB7
The post suggests executing the following command in the debugger console:
process handle SIGPIPE -n false -s false
If I set a breakpoint in the first line of my application's main() function
and then enable the Debugger Log view in Creator, I can execute this
command and, after I continue execution, I no longer hit a breakpoint when
the library sends the SIGPIPE signal.
The problem is that it is cumbersome to execute this command every time I
start debugging my application. I see that in the Qt Creator preferences
dialog, there is a place to add Additional Startup Commands for GDB. I
tried putting the command here, but these commands are apparently not
executed when lldb starts.
I could (and probably will) create a feature request for the ability to add
startup commands for lldb, but I wondered if anyone else has run into this
issue and been able to solve it in a more elegant way.
Even better would be a way that I could alter the project itself to prevent
lldb from breaking on this signal, but I doubt that's possible.
Thanks for any help
Adam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20150515/726ae49c/attachment.html>
More information about the Qt-creator
mailing list