* [PATCH] nptl: Fix typo in error message
@ 2022-09-29 8:57 Yu Chien Peter Lin
2022-09-29 10:01 ` Florian Weimer
0 siblings, 1 reply; 3+ messages in thread
From: Yu Chien Peter Lin @ 2022-09-29 8:57 UTC (permalink / raw)
To: libc-alpha; +Cc: alankao, ycliang, fweimer, Yu Chien Peter Lin
Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
---
nptl/tst-setuid2.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/nptl/tst-setuid2.c b/nptl/tst-setuid2.c
index aff3b1a97d..fed2671b01 100644
--- a/nptl/tst-setuid2.c
+++ b/nptl/tst-setuid2.c
@@ -77,7 +77,7 @@ run_on_thread (void (*func) (void))
ret = pthread_cond_signal (&cond_send);
if (ret != 0)
- FAIL ("pthread_mutex_lock (%s): %d", __func__, ret);
+ FAIL ("pthread_cond_signal (send): %d", ret);
ret = pthread_mutex_lock (&mutex);
if (ret != 0)
@@ -87,7 +87,7 @@ run_on_thread (void (*func) (void))
{
ret = pthread_cond_wait (&cond_recv, &mutex);
if (ret != 0)
- FAIL ("pthread_mutex_wait (%s): %d", __func__, ret);
+ FAIL ("pthread_cond_wait (recv): %d", ret);
}
ret = pthread_mutex_unlock (&mutex);
if (ret != 0)
--
2.34.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] nptl: Fix typo in error message
2022-09-29 8:57 [PATCH] nptl: Fix typo in error message Yu Chien Peter Lin
@ 2022-09-29 10:01 ` Florian Weimer
2022-09-30 14:28 ` Yu-Chien Peter Lin
0 siblings, 1 reply; 3+ messages in thread
From: Florian Weimer @ 2022-09-29 10:01 UTC (permalink / raw)
To: Yu Chien Peter Lin; +Cc: libc-alpha, fweimer, ycliang, alankao
* Yu Chien Peter Lin:
> Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
> ---
> nptl/tst-setuid2.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/nptl/tst-setuid2.c b/nptl/tst-setuid2.c
> index aff3b1a97d..fed2671b01 100644
> --- a/nptl/tst-setuid2.c
> +++ b/nptl/tst-setuid2.c
> @@ -77,7 +77,7 @@ run_on_thread (void (*func) (void))
>
> ret = pthread_cond_signal (&cond_send);
> if (ret != 0)
> - FAIL ("pthread_mutex_lock (%s): %d", __func__, ret);
> + FAIL ("pthread_cond_signal (send): %d", ret);
>
> ret = pthread_mutex_lock (&mutex);
> if (ret != 0)
> @@ -87,7 +87,7 @@ run_on_thread (void (*func) (void))
> {
> ret = pthread_cond_wait (&cond_recv, &mutex);
> if (ret != 0)
> - FAIL ("pthread_mutex_wait (%s): %d", __func__, ret);
> + FAIL ("pthread_cond_wait (recv): %d", ret);
> }
> ret = pthread_mutex_unlock (&mutex);
> if (ret != 0)
Maybe introduce xpthread_cond_signal in a separate patch and use
xpthread_cond_signal and xpthread_cond_wait instead? The latter
already exists.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] nptl: Fix typo in error message
2022-09-29 10:01 ` Florian Weimer
@ 2022-09-30 14:28 ` Yu-Chien Peter Lin
0 siblings, 0 replies; 3+ messages in thread
From: Yu-Chien Peter Lin @ 2022-09-30 14:28 UTC (permalink / raw)
To: Florian Weimer; +Cc: libc-alpha, fweimer, ycliang, alankao
On Thu, Sep 29, 2022 at 12:01:38PM +0200, Florian Weimer wrote:
> * Yu Chien Peter Lin:
>
> > Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
> > ---
> > nptl/tst-setuid2.c | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/nptl/tst-setuid2.c b/nptl/tst-setuid2.c
> > index aff3b1a97d..fed2671b01 100644
> > --- a/nptl/tst-setuid2.c
> > +++ b/nptl/tst-setuid2.c
> > @@ -77,7 +77,7 @@ run_on_thread (void (*func) (void))
> >
> > ret = pthread_cond_signal (&cond_send);
> > if (ret != 0)
> > - FAIL ("pthread_mutex_lock (%s): %d", __func__, ret);
> > + FAIL ("pthread_cond_signal (send): %d", ret);
> >
> > ret = pthread_mutex_lock (&mutex);
> > if (ret != 0)
> > @@ -87,7 +87,7 @@ run_on_thread (void (*func) (void))
> > {
> > ret = pthread_cond_wait (&cond_recv, &mutex);
> > if (ret != 0)
> > - FAIL ("pthread_mutex_wait (%s): %d", __func__, ret);
> > + FAIL ("pthread_cond_wait (recv): %d", ret);
> > }
> > ret = pthread_mutex_unlock (&mutex);
> > if (ret != 0)
>
> Maybe introduce xpthread_cond_signal in a separate patch and use
> xpthread_cond_signal and xpthread_cond_wait instead? The latter
> already exists.
Hi, Florian
I would introduce xpthread_cond_signal with a new patch, and also use
test-driver.c, thanks for your suggestion.
Best regards,
Peter Lin
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-09-30 6:31 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-29 8:57 [PATCH] nptl: Fix typo in error message Yu Chien Peter Lin
2022-09-29 10:01 ` Florian Weimer
2022-09-30 14:28 ` Yu-Chien Peter Lin
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).