if seconds are specified, min is 1
This commit is contained in:
parent
d83962d3f5
commit
1b7b1ca15e
1 changed files with 2 additions and 0 deletions
|
@ -109,6 +109,8 @@ class ActionModule(ActionBase):
|
||||||
old_settings = None
|
old_settings = None
|
||||||
try:
|
try:
|
||||||
if seconds is not None:
|
if seconds is not None:
|
||||||
|
if seconds < 1:
|
||||||
|
seconds = 1
|
||||||
# setup the alarm handler
|
# setup the alarm handler
|
||||||
signal.signal(signal.SIGALRM, timeout_handler)
|
signal.signal(signal.SIGALRM, timeout_handler)
|
||||||
signal.alarm(seconds)
|
signal.alarm(seconds)
|
||||||
|
|
Loading…
Reference in a new issue