Skip to content

Commit 8536c2e

Browse files
committed
Fix pidfile operation failure
1 parent 74c1fe5 commit 8536c2e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/commandline.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ parse_commandline(int argc, char **argv)
9393
i = 0;
9494
restartargv[i++] = safe_strdup(argv[0]);
9595

96-
while (-1 != (c = getopt(argc, argv, "c:hfd:sw:vx:i:a:"))) {
96+
while (-1 != (c = getopt(argc, argv, "c:hfd:sw:vx:i:a:p:"))) {
9797

9898
skiponrestart = 0;
9999

src/gateway.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ main_loop(void)
367367
}
368368

369369
/* save the pid file if needed */
370-
if ((!config) && (!config->pidfile))
370+
if (config && config->pidfile)
371371
save_pid_file(config->pidfile);
372372

373373
/* If we don't have the Gateway IP address, get it. Can't fail. */

0 commit comments

Comments
 (0)