summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2023-03-28 07:30:29 +0000
committerLaurent Bercot <ska@appnovation.com>2023-03-28 07:30:29 +0000
commita09b6ddc286efb3a3c6e95ea1bb74431205e9cea (patch)
treecf29d48581690c79978b1e23323050b5ba62ac7b
parentf703e8dcaf7de182c88f427bece97658941857f7 (diff)
downloadexecline-a09b6ddc286efb3a3c6e95ea1bb74431205e9cea.tar.xz
regression fix: initialize pids in the trap main function
Signed-off-by: Laurent Bercot <ska@appnovation.com>
-rw-r--r--AUTHORS1
-rw-r--r--NEWS1
-rw-r--r--src/execline/trap.c2
3 files changed, 3 insertions, 1 deletions
diff --git a/AUTHORS b/AUTHORS
index 506be68..21d58d0 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -11,6 +11,7 @@ Contributors:
Alexis <flexibeast@gmail.com>
Dominique Martinet <asmadeus@codewreck.org>
Christian Hohnstaedt <christian@hohnstaedt.de>
+ Eugen Wissner <belka@caraus.de>
Thanks to:
Dan J. Bernstein <djb@cr.yp.to>
diff --git a/NEWS b/NEWS
index a0b148a..08f26bd 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,7 @@ Changelog for execline.
In 2.9.3.0
----------
+ - Bugfixes.
- New -D option to elgetopt.
diff --git a/src/execline/trap.c b/src/execline/trap.c
index 52541ca..b409d77 100644
--- a/src/execline/trap.c
+++ b/src/execline/trap.c
@@ -45,7 +45,7 @@ static inline void trap_action (unsigned int i, char const *const *envp, size_t
int main (int argc, char const **argv, char const *const *envp)
{
- pid_t pids[SKALIBS_NSIG + 1] ;
+ pid_t pids[SKALIBS_NSIG + 1] = { 0 } ;
char const *const *argvs[SKALIBS_NSIG] = { 0 } ;
size_t envlen = env_len(envp) ;
iopause_fd x = { .events = IOPAUSE_READ } ;