Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libpthread fake-use alloca()'s return value to quieten -...
details: https://anonhg.NetBSD.org/src/rev/7129d5a13650
branches: trunk
changeset: 1020456:7129d5a13650
user: mrg <mrg%NetBSD.org@localhost>
date: Tue Apr 13 00:31:54 2021 +0000
description:
fake-use alloca()'s return value to quieten -Werror=unused-result
diffstat:
lib/libpthread/pthread.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (35 lines):
diff -r d60faee0ae4e -r 7129d5a13650 lib/libpthread/pthread.c
--- a/lib/libpthread/pthread.c Tue Apr 13 00:29:42 2021 +0000
+++ b/lib/libpthread/pthread.c Tue Apr 13 00:31:54 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pthread.c,v 1.178 2020/07/22 01:24:39 msaitoh Exp $ */
+/* $NetBSD: pthread.c,v 1.179 2021/04/13 00:31:54 mrg Exp $ */
/*-
* Copyright (c) 2001, 2002, 2003, 2006, 2007, 2008, 2020
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: pthread.c,v 1.178 2020/07/22 01:24:39 msaitoh Exp $");
+__RCSID("$NetBSD: pthread.c,v 1.179 2021/04/13 00:31:54 mrg Exp $");
#define __EXPOSE_STACK 1
@@ -535,6 +535,7 @@
{
pthread_t self;
void *retval;
+ void *junk __unused;
self = cookie;
@@ -544,7 +545,7 @@
* be allocating stacks on fixed 2MB boundaries. Needs a
* thread register or decent thread local storage.
*/
- (void)alloca(((unsigned)self->pt_lid & 7) << 8);
+ junk = alloca(((unsigned)self->pt_lid & 7) << 8);
if (self->pt_name != NULL) {
pthread_mutex_lock(&self->pt_lock);
Home |
Main Index |
Thread Index |
Old Index