diff options
author | 2012-02-19 04:47:49 +0000 | |
---|---|---|
committer | 2012-02-19 04:47:49 +0000 | |
commit | fda5566566e74292cd22899f3fa0ff1af8f7dc39 (patch) | |
tree | 29ac3eb828c2741e54654ae74ff1de20630eca4a | |
parent | Validate in pthread_attr_set{scope,sched{param,policy},inheritsched}() (diff) | |
download | wireguard-openbsd-fda5566566e74292cd22899f3fa0ff1af8f7dc39.tar.xz wireguard-openbsd-fda5566566e74292cd22899f3fa0ff1af8f7dc39.zip |
Use a form of designated initializer that works with gcc2
lint doesn't understand designated initializers, so hide them from it
-rw-r--r-- | lib/librthread/rthread.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/librthread/rthread.c b/lib/librthread/rthread.c index 65d5c6a0f32..a2784283319 100644 --- a/lib/librthread/rthread.c +++ b/lib/librthread/rthread.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rthread.c,v 1.53 2012/02/18 22:03:21 guenther Exp $ */ +/* $OpenBSD: rthread.c,v 1.54 2012/02/19 04:47:49 guenther Exp $ */ /* * Copyright (c) 2004,2005 Ted Unangst <tedu@openbsd.org> * All Rights Reserved. @@ -51,15 +51,19 @@ struct thread_control_block _initial_thread_tcb; int __tfork_thread(const struct __tfork *, void *, void (*)(void *), void *); struct pthread_attr _rthread_attr_default = { +#ifndef lint .stack_addr = NULL, .stack_size = RTHREAD_STACK_SIZE_DEF, /* .guard_size set in _rthread_init */ .detach_state = PTHREAD_CREATE_JOINABLE, .contention_scope = PTHREAD_SCOPE_SYSTEM, .sched_policy = SCHED_OTHER, - .sched_param.sched_priority = 0, + .sched_param = { .sched_priority = 0 }, .sched_inherit = PTHREAD_INHERIT_SCHED, .create_suspended = 0, +#else + 0 +#endif }; /* @@ -111,6 +115,7 @@ _rthread_start(void *v) pthread_exit(retval); } +/* ARGSUSED0 */ static void sigthr_handler(__unused int sig) { |