linux-man.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Kerrisk <mtk.manpages-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org>
To: bill o gallmeister <bog.kernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Petre Mierlutiu <peter-zTtBy73WAK9hl2p70BpVqQ@public.gmane.org>,
	linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Subject: [PATCH] sleep.3: sleep suspends the thread, not the process. (Re: sleep(3) manpage)
Date: Wed, 3 Feb 2010 07:01:35 +0100	[thread overview]
Message-ID: <cfd18e0f1002022201g9923cemfe3e7a8cbc481355@mail.gmail.com> (raw)
In-Reply-To: <4B57F6F0.8010904-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

On Thu, Jan 21, 2010 at 7:40 AM, bill o gallmeister
<bog.kernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> Petre Mierlutiu wrote:
>> Hello,
>>
>> the sleep(3) manpage states, under DESCRIPTION, that "sleep()  makes  the  calling  process sleep [...]". I believe this not to be true and the appropriate text would be: "sleep() makes the calling thread sleep [...]".
>>
>>  I think in the past Linux did implement it so it would block the process, I am not sure.
>> Anyway, sleep is currently implemented using nanosleep() and a simple threaded program can be written to prove sleep only sleeps the calling thread.
>>
>> Manpages version: 3.21
>> Distribution: ubuntu 9.10
>>
>> Kind regards,
>>
>> Petre Mierlutiu--
>> To unsubscribe from this list: send the line "unsubscribe linux-man" in
>> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>
>
> Signed-off-by: Bill O. Gallmeister <bog.kernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

Thanks Bill.

Applied for 3.24.

Cheers,

Michael


> ---
>  man3/sleep.3 |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/man3/sleep.3 b/man3/sleep.3
> index 900b7fc..41575b7 100644
> --- a/man3/sleep.3
> +++ b/man3/sleep.3
> @@ -32,7 +32,7 @@ sleep \- Sleep for the specified number of seconds
>  .fi
>  .SH DESCRIPTION
>  .BR sleep ()
> -makes the calling process sleep until
> +makes the calling thread sleep until
>  .I seconds
>  seconds have elapsed or a signal arrives which is not ignored.
>  .SH "RETURN VALUE"
> @@ -58,5 +58,6 @@ from a signal handler or modifying the handling of
>  while sleeping will cause undefined results.
>  .SH "SEE ALSO"
>  .BR alarm (2),
> +.BR nanosleep (2),
>  .BR signal (2),
>  .BR signal (7)
> --
> 1.6.0.6
>



-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface" http://blog.man7.org/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

      parent reply	other threads:[~2010-02-03  6:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-10 17:50 sleep(3) manpage Petre Mierlutiu
     [not found] ` <9C1C3093-079B-4125-8621-56628C4A963B-zTtBy73WAK9hl2p70BpVqQ@public.gmane.org>
2010-01-21  6:40   ` Subject: [PATCH] sleep.3: sleep suspends the thread, not the process. (Re: sleep(3) manpage) bill o gallmeister
     [not found]     ` <4B57F6F0.8010904-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-02-03  6:01       ` Michael Kerrisk [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=cfd18e0f1002022201g9923cemfe3e7a8cbc481355@mail.gmail.com \
    --to=mtk.manpages-gm/ye1e23mwn+bqq9rbeug@public.gmane.org \
    --cc=bog.kernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=peter-zTtBy73WAK9hl2p70BpVqQ@public.gmane.org \
    /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;
as well as URLs for NNTP newsgroup(s).