Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Petr Vandrovec <vandrove@vc.cvut.cz>
To: Mark Kettenis <mark.kettenis@xs4all.nl>
Cc: ying lcs <yinglcs@gmail.com>,  gdb@sourceware.org
Subject: Re: Program received signal SIG33, Real-time event 33.
Date: Mon, 03 Sep 2007 08:04:00 -0000	[thread overview]
Message-ID: <46DBBFF8.4050809@vc.cvut.cz> (raw)
In-Reply-To: <200709030747.l837lEW6011975@brahms.sibelius.xs4all.nl>

Mark Kettenis wrote:
>> Date: Sun, 02 Sep 2007 19:24:08 -0700
>> From: Petr Vandrovec <vandrove@vc.cvut.cz>
>>
>> Daniel Jacobowitz wrote:
>>> On Sun, Sep 02, 2007 at 12:50:46AM -0700, Petr Vandrovec wrote:
>>>> Apparently your program uses signals...  If this is expected (which probably is 
>>>> for realtime signals) then
>>>>
>>>> handle SIG33 nostop noprint pass
>>>>
>>>> will configure gdb so this signal is ignored by gdb, but delivered to program 
>>>> like without gdb.
>>> No, SIG33 is generally internal to the threading implementation.
>>>
>>> GDB 6.3 is somewhat old.  I recommend trying a current version.
>> If Ying uses setuid() from multithreaded program then I think that glibc 
>> has more than one surprise ready for him...
> 
> Is that still broken on Linux?

Hello,

It depends on what do you mean by broken.

Yes, it now follows Posix which says that uid/euid is common to all 
threads.  Yes, it is implemented by sending some reserved signal (I 
believe 33...) to every thread, and then every thread calls kernel's 
setXid on its own from signal handler.  And no, I never saw 
multithreaded application which expects/wants this behavior.

Fortunately kernel API is still there, so people like me writting 
multithreaded setuid applications now use kernel directly, avoiding 
glibc's wrappers.
							Petr


      reply	other threads:[~2007-09-03  8:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-02  5:54 ying lcs
2007-09-02  7:50 ` Petr Vandrovec
2007-09-02 13:44   ` Daniel Jacobowitz
2007-09-03  2:24     ` Petr Vandrovec
2007-09-03  3:07       ` ying lcs
2007-09-03  7:47       ` Mark Kettenis
2007-09-03  8:04         ` Petr Vandrovec [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46DBBFF8.4050809@vc.cvut.cz \
    --to=vandrove@vc.cvut.cz \
    --cc=gdb@sourceware.org \
    --cc=mark.kettenis@xs4all.nl \
    --cc=yinglcs@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox