mirror of
https://github.com/onionshare/onionshare.git
synced 2025-12-16 08:44:14 -05:00
Don't allow setting an auto-stop timer that is shorter than the auto-start timer
This commit is contained in:
parent
84aa627d1f
commit
2dcda9d473
1 changed files with 5 additions and 0 deletions
|
|
@ -134,6 +134,11 @@ def main(cwd=None):
|
||||||
app.choose_port()
|
app.choose_port()
|
||||||
# Delay the startup if a startup timer was set
|
# Delay the startup if a startup timer was set
|
||||||
if startup_timer > 0:
|
if startup_timer > 0:
|
||||||
|
# Can't set a schedule that is later than the shutdown timer
|
||||||
|
if app.shutdown_timeout > 0 and app.shutdown_timeout < startup_timer:
|
||||||
|
print(strings._('gui_timeout_cant_be_earlier_than_startup'))
|
||||||
|
sys.exit()
|
||||||
|
|
||||||
app.start_onion_service(False, True)
|
app.start_onion_service(False, True)
|
||||||
if common.settings.get('public_mode'):
|
if common.settings.get('public_mode'):
|
||||||
url = 'http://{0:s}'.format(app.onion_host)
|
url = 'http://{0:s}'.format(app.onion_host)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue