Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: bug-readline@gnu.org, gdb-patches@sources.redhat.com
Subject: Re: PATCH: Readline on MinGW
Date: Thu, 28 Apr 2005 21:17:00 -0000	[thread overview]
Message-ID: <20050428211735.GA17310@nevyn.them.org> (raw)
In-Reply-To: <01c54c33$Blat.v2.4$bff25520@zahav.net.il>

On Thu, Apr 28, 2005 at 11:48:17PM +0300, Eli Zaretskii wrote:
> > Date: Thu, 28 Apr 2005 16:12:15 -0400
> > From: Daniel Jacobowitz <drow@false.org>
> > Cc: Mark Mitchell <mark@codesourcery.com>, bug-readline@gnu.org,
> > 	gdb-patches@sources.redhat.com
> > 
> > Could you give me a reference for this?  POSIX disagrees:
> > 
> >   http://www.opengroup.org/onlinepubs/009695399/functions/raise.html
> 
> Well, perhaps I misunderstand the language of Posix, but in this text:
> 
>   Otherwise, the effect of the raise() function shall be equivalent to calling:
> 
>   kill(getpid(), sig);
> 
> why did they use "Otherwise"?  To me, this says that `raise' is not
> always the equivalent of `kill''.

Because in an environment which supports multiple threads, it behaves
as pthread_kill (pthread_self(), sig) as described above.  Which does:

  The pthread_kill() function shall request that a signal be delivered to
  the specified thread.

  As in kill(), if sig is zero, error checking shall be performed but
  no signal shall actually be sent.

> In any case, it is traditional on Posix platforms to use `kill', not
> `raise'.  I think the latter was introduced by ANSI/ISO C; if Readline
> does not mandate an ISO C compiler like GDB does, it would make more
> sense to use `raise' only if `kill' is unavailable.

This isn't right.  POSIX mandates the existence of raise; ANSI/ISO C
does not specify anything having to do with signals.

Anyway, I've got no problem with using autoconf for this, but I can't
think of any case where it would make a difference.

-- 
Daniel Jacobowitz
CodeSourcery, LLC


  reply	other threads:[~2005-04-28 21:17 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-28  6:53 Mark Mitchell
2005-04-28 20:09 ` Eli Zaretskii
2005-04-28 20:12   ` Daniel Jacobowitz
2005-04-28 20:45     ` Mark Mitchell
2005-04-28 21:02       ` Chet Ramey
2005-04-29  0:44         ` Mark Mitchell
2005-04-29  7:31           ` Eli Zaretskii
2005-04-29 16:10             ` Christopher Faylor
2005-04-29  1:51         ` Mark Mitchell
2005-04-28 21:02       ` Eli Zaretskii
2005-04-28 20:50     ` Eli Zaretskii
2005-04-28 21:17       ` Daniel Jacobowitz [this message]
2005-04-28 22:13         ` Andreas Schwab
2005-04-29  6:59         ` Eli Zaretskii

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=20050428211735.GA17310@nevyn.them.org \
    --to=drow@false.org \
    --cc=bug-readline@gnu.org \
    --cc=eliz@gnu.org \
    --cc=gdb-patches@sources.redhat.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