Browse Source

*nargv[] holds an array of pointers, so it should be

terminated by a null pointer.
ok rzalamena@ reyk@
OPENBSD_6_1
gsoares 7 years ago
parent
commit
ef079a5b2e
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/usr.sbin/ntpd/util.c

+ 2
- 2
src/usr.sbin/ntpd/util.c View File

@ -1,4 +1,4 @@
/* $OpenBSD: util.c,v 1.23 2016/10/03 12:30:43 rzalamena Exp $ */
/* $OpenBSD: util.c,v 1.24 2017/03/01 00:56:30 gsoares Exp $ */
/* /*
* Copyright (c) 2004 Alexander Guy <alexander.guy@andern.org> * Copyright (c) 2004 Alexander Guy <alexander.guy@andern.org>
@ -177,7 +177,7 @@ start_child(char *pname, int cfd, int argc, char **argv)
for (i = 1; i < argc; i++) for (i = 1; i < argc; i++)
nargv[nargc++] = argv[i]; nargv[nargc++] = argv[i];
nargv[nargc] = 0;
nargv[nargc] = NULL;
switch (pid = fork()) { switch (pid = fork()) {
case -1: case -1:


Loading…
Cancel
Save