Skip to content

Commit 5ff7117

Browse files
committed
fix: pdeathsig option is not defined under Mac, so it was AttributeError
1 parent 1d249a9 commit 5ff7117

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

zk-flock

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,11 +313,13 @@ if __name__ == "__main__":
313313
if want_to_sleep == "ON":
314314
time.sleep(get_la())
315315

316+
pdeathsig_num = getattr(options, "pdeathsig", 0)
317+
316318
if options.isdaemonize:
317319
daemon = Daemon()
318320
daemon.run = main
319321
daemon.start(cmd_arg, cfg, options.waittime,
320-
options.exitcode, options.sequence, options.pdeathsig)
322+
options.exitcode, options.sequence, pdeathsig_num)
321323
else:
322324
main(cmd_arg, cfg, options.waittime,
323-
options.exitcode, options.sequence, options.pdeathsig)
325+
options.exitcode, options.sequence, pdeathsig_num)

0 commit comments

Comments
 (0)