mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
Use exit(1) on errors
This commit is contained in:
parent
867f1f80df
commit
b9e2174fe9
1 changed files with 3 additions and 3 deletions
|
@ -19,18 +19,18 @@ try:
|
|||
post_data = open(sys.argv[2], 'rb')
|
||||
except:
|
||||
print('file ' + sys.argv[2] + ' not found')
|
||||
exit()
|
||||
exit(1)
|
||||
|
||||
try:
|
||||
post_request = urllib.request.Request(post_url, post_data, post_headers)
|
||||
except:
|
||||
print('urllib.request.Request failed')
|
||||
exit()
|
||||
exit(1)
|
||||
|
||||
try:
|
||||
post_response = urllib.request.urlopen(post_request)
|
||||
except:
|
||||
print('urllib.request.urlopen failed')
|
||||
exit()
|
||||
exit(1)
|
||||
|
||||
print("Upload to BackTrace completed without errors")
|
Loading…
Reference in a new issue