Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Fernando Nasser <fnasser@redhat.com>
To: Michael Snyder <msnyder@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: RFA: EINTR in procfs_wait
Date: Fri, 13 Apr 2001 06:53:00 -0000	[thread overview]
Message-ID: <3AD70404.F37729DA@redhat.com> (raw)
In-Reply-To: <3AD4EC75.C2C1DF5E@cygnus.com>

Michael Snyder wrote:
> 
> Fernando Nasser wrote:
> >
> > Folks,
> >
> > I got this patch and it seems that we did forget to test for EINTR in
> > procfs_wait(). It looks like an "obvious fix" but I would like someone
> > else to double check it.
> 
> OK, I've looked at the old procfs module, and it did indeed have a similar
> test in a similar (though not identical) context.  The change makes sense
> to me.  Fernando, do you want to do the honors?
> 

I checked Adam's patch in.

Fernando


> >
> > Thanks in advance.
> >
> > Fernando
> >
> > 2001-04-05  Adam Mirowski  <Adam.Mirowski@Sun.COM>
> >
> >         Fixed Insight on Solaris. It was not possible to debug a process
> >         because of EINTR "errors".
> >         * procfs.c: (procfs_wait): if proc_wait_for_stop() fails
> >         with EINTR, retry the call.
> >
> > Index: gdb/procfs.c
> > ------- procfs.c -------
> > *** /tmp/dMKayx_        Tue Apr 10 16:20:54 2001
> > --- procfs.c    Thu Apr  5 22:21:40 2001
> > ***************
> > *** 3518,3531 ****
> > --- 3518,3533 ----
> >
> >               if (retval != PIDGET (inferior_pid))      /* wrong child? */
> >                 error ("procfs: couldn't stop process %d: wait returned %d\n",
> >                        inferior_pid, retval);
> >               /* FIXME: might I not just use waitpid?
> >                  Or try find_procinfo to see if I know about this child? */
> >             }
> > +         else if (errno == EINTR)
> > +           goto wait_again;
> >           else
> >             {
> >               /* Unknown error from wait_for_stop. */
> >               proc_error (pi, "target_wait (wait_for_stop)", __LINE__);
> >             }
> >         }
> >         else

-- 
Fernando Nasser
Red Hat Canada Ltd.                     E-Mail:  fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario   M4P 2C9


      reply	other threads:[~2001-04-13  6:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-10  8:08 Fernando Nasser
2001-04-10 14:57 ` Kevin Buettner
2001-04-10 17:41   ` Fernando Nasser
2001-04-11 16:43   ` Michael Snyder
2001-04-11 11:13 ` Andrew Cagney
2001-04-11 16:45 ` Michael Snyder
2001-04-13  6:53   ` Fernando Nasser [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=3AD70404.F37729DA@redhat.com \
    --to=fnasser@redhat.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=msnyder@cygnus.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