diff options
author | 2012-03-22 15:43:08 +0000 | |
---|---|---|
committer | 2012-03-22 15:43:08 +0000 | |
commit | 9e9b8682c3695d2f785a98f71d2e267032d9c4ea (patch) | |
tree | bd02fe770d67f77f857eec99eea27d77f7786688 /lib/libc/gen/posix_spawn.c | |
parent | Remove pthread_suspend* and related functions. This is part of the (diff) | |
download | wireguard-openbsd-9e9b8682c3695d2f785a98f71d2e267032d9c4ea.tar.xz wireguard-openbsd-9e9b8682c3695d2f785a98f71d2e267032d9c4ea.zip |
clean the sigact in a portable way; ok matthew
Diffstat (limited to 'lib/libc/gen/posix_spawn.c')
-rw-r--r-- | lib/libc/gen/posix_spawn.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/libc/gen/posix_spawn.c b/lib/libc/gen/posix_spawn.c index cf1fadb1ef0..45fbb1973de 100644 --- a/lib/libc/gen/posix_spawn.c +++ b/lib/libc/gen/posix_spawn.c @@ -1,4 +1,4 @@ -/* $OpenBSD: posix_spawn.c,v 1.1 2012/03/21 23:20:35 matthew Exp $ */ +/* $OpenBSD: posix_spawn.c,v 1.2 2012/03/22 15:43:08 deraadt Exp $ */ /*- * Copyright (c) 2008 Ed Schouten <ed@FreeBSD.org> * All rights reserved. @@ -82,9 +82,12 @@ typedef struct __posix_spawn_file_actions_entry { static int process_spawnattr(const posix_spawnattr_t sa) { - struct sigaction sigact = { .sa_flags = 0, .sa_handler = SIG_DFL }; + struct sigaction sigact; int i; + memset(&sigact, 0, sizeof(sigact)); + sigact.sa_handler = SIG_DFL; + /* * POSIX doesn't really describe in which order everything * should be set. We'll just set them in the order in which they |