From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11237 invoked by alias); 3 Sep 2007 08:04:17 -0000 Received: (qmail 11225 invoked by uid 22791); 3 Sep 2007 08:04:16 -0000 X-Spam-Check-By: sourceware.org Received: from mailgw.cvut.cz (HELO mailgw.cvut.cz) (147.32.3.235) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 03 Sep 2007 08:04:11 +0000 Received: from mailgw (localhost [127.0.0.1]) by mailgw.cvut.cz (Postfix) with SMTP id 9771D13B66E; Mon, 3 Sep 2007 10:04:09 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by mailgw.cvut.cz (Postfix) with ESMTP id 59C7313B993; Mon, 3 Sep 2007 10:04:09 +0200 (CEST) Received: from mailgw.cvut.cz ([127.0.0.1]) by localhost (mailgw [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 16534-14; Mon, 3 Sep 2007 10:04:09 +0200 (CEST) Received: from [127.0.0.1] (buk.vc.cvut.cz [147.32.240.88]) by mailgw.cvut.cz (Postfix) with ESMTP id 4407913B66E; Mon, 3 Sep 2007 10:04:08 +0200 (CEST) Message-ID: <46DBBFF8.4050809@vc.cvut.cz> Date: Mon, 03 Sep 2007 08:04:00 -0000 From: Petr Vandrovec User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.8.1.6) Gecko/20070802 Iceape/1.1.4 (Debian-1.1.4-1) MIME-Version: 1.0 To: Mark Kettenis CC: ying lcs , gdb@sourceware.org Subject: Re: Program received signal SIG33, Real-time event 33. References: <568e62a40709012254j43aa5c15i9c7612350a77de55@mail.gmail.com> <46DA6B56.1060200@vc.cvut.cz> <20070902134404.GA5557@caradoc.them.org> <46DB7048.7050309@vc.cvut.cz> <200709030747.l837lEW6011975@brahms.sibelius.xs4all.nl> In-Reply-To: <200709030747.l837lEW6011975@brahms.sibelius.xs4all.nl> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-09/txt/msg00013.txt.bz2 Mark Kettenis wrote: >> Date: Sun, 02 Sep 2007 19:24:08 -0700 >> From: Petr Vandrovec >> >> 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