From: y00575850 <yangyanchao6@huawei.com>
To: <libc-stable@sourceware.org>
Cc: <wuxu.wu@huawei.com>, <carlos@systemhalted.org>
Subject: sem_timedwait: The semaphore times out when the clock_REALTIME is used.
Date: Tue, 6 Apr 2021 21:09:33 +0800 [thread overview]
Message-ID: <20210406130933.1915-1-yangyanchao6@huawei.com> (raw)
Dear Carlos,
When I use sem_timedwait, a time jump will cause the semaphore to time out.
While I know that using CLOCK_REALTIME is POSIX-defined behavior, it doesn't
fit the actual meaning of this function.To solve this problem, modify the
sem_timedwait process, for example: add a switch control.
Or add an interface that uses the Clock_MONOTONIC interface.
Best regards,
Yanchao
next reply other threads:[~2021-04-06 13:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-06 13:09 y00575850 [this message]
2021-04-08 14:10 ` Szabolcs Nagy
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=20210406130933.1915-1-yangyanchao6@huawei.com \
--to=yangyanchao6@huawei.com \
--cc=carlos@systemhalted.org \
--cc=libc-stable@sourceware.org \
--cc=wuxu.wu@huawei.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).