From b58f145c754025893d5e50dc9c8b21786660103c Mon Sep 17 00:00:00 2001 From: zrj Date: Thu, 18 Apr 2019 23:01:47 +0300 Subject: [PATCH] libc: Implement properly pthread_equal() stub. Functional stub is needed to avoid forcing thread library on librecrypto. --- lib/libc/gen/_pthread_stubs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/libc/gen/_pthread_stubs.c b/lib/libc/gen/_pthread_stubs.c index 631446dd75..04aa58123e 100644 --- a/lib/libc/gen/_pthread_stubs.c +++ b/lib/libc/gen/_pthread_stubs.c @@ -95,7 +95,7 @@ WR(stub_zero, pthread_condattr_init); WR(stub_zero, pthread_condattr_setclock); WR(stub_zero, pthread_condattr_setpshared); WR(stub_zero, pthread_detach); -WR(stub_true, pthread_equal); +WR(stub_equal, pthread_equal); WR(stub_exit, pthread_exit); WR(stub_zero, pthread_getaffinity_np); WR(stub_zero, pthread_getconcurrency); @@ -220,9 +220,9 @@ stub_main(void) } static int __used -stub_true(void) +stub_equal(pthread_t a, pthread_t b) { - return (1); + return (a == b); } static void __used -- 2.41.0