Sorry, Jens and Pascal!
I have received your messages just now.
You were right, as I have found out a while later kind of the hard way ...
So, thanks again!
Best regards, Gabriel
smime.p7s
Description: S/MIME cryptographic signature
___
Cocoa-dev
I think , I found the solution, so just for the record
(so that others will find it using Google):
Launch the app in the debugger on the command line :
lldb /private/tmp/Build/Products/Debug/MyApp.app
In lldb's command line:
process handle -p true -s false -n true // otherwise lldb will
Hi Gabriel. Happy that you’re getting some progress. Did Jens’s reply not
explain why it would be interfered with when running in the debugger?
> On Jan 31, 2024, at 10:33 AM, Gabriel Zachmann via Cocoa-dev
> wrote:
>
> I have investigated a bit further.
>
> When I launch my app from lldb (
I have investigated a bit further.
When I launch my app from lldb (on the command line),
it still stops in mach_msg2_trap when I send a SIGUSR1 to my app.
But at least, I get a more meaningful stack trace:
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGUSR1
* frame #0: 0
ss them through to the
> process being debugged) by breaking into the debugger, then enter in the
> Xcode console part (example for SIGUSR1):
>
> process handle SIGUSR1 -s false
> process handle SIGUSR1 -p true
>
> HTH,
> -jens
>
>
>> Von: Gabriel
false
process handle SIGUSR1 -p true
HTH,
-jens
> Von: Gabriel Zachmann
> Betreff: Xcode interferes with signal handler (was: Sending SIGUSR1 to a
> process)
> Datum: 30. Januar 2024 um 20:31:45 MEZ
> An: "cocoa-dev@lists.apple.com"
>
>
> I am set
Le 30/01/2024 à 20:31, Gabriel Zachmann via Cocoa-dev a écrit :
I am setting up a signal handler in my app like this:
void *e = signal( SIGUSR1, signal_handler );
if ( e == SIG_ERR )
...
It works (i can 'kill -30 '), BUT ONLY, if I run my app outside of Xcode.
When I launch it f
I am setting up a signal handler in my app like this:
void *e = signal( SIGUSR1, signal_handler );
if ( e == SIG_ERR )
...
It works (i can 'kill -30 '), BUT ONLY, if I run my app outside of Xcode.
When I launch it from Xcode, and I send a SIGUSR1 to my app, it always breaks
at mach_