Merge "Using sys.exit(main()) instead of main()"

This commit is contained in:
Jenkins 2016-10-19 02:44:48 +00:00 committed by Gerrit Code Review
commit 7fa57eadbd
5 changed files with 7 additions and 5 deletions

View File

@ -362,4 +362,4 @@ def main():
pprint.pformat(resp.json())))
if __name__ == '__main__':
main()
sys.exit(main())

View File

@ -208,4 +208,4 @@ def main():
LOG.error(e)
if __name__ == '__main__':
main()
sys.exit(main())

View File

@ -46,6 +46,7 @@ import os
import random
import string
import time
import sys
import dns
import dns.resolver
@ -660,4 +661,4 @@ def main():
if __name__ == '__main__':
main()
sys.exit(main())

View File

@ -19,6 +19,7 @@ Log to stdout or to a file.
"""
from argparse import ArgumentParser
import sys
from time import gmtime
from time import strftime
import SocketServer
@ -57,4 +58,4 @@ def main():
server.serve_forever()
if __name__ == "__main__":
main()
sys.exit(main())

View File

@ -88,4 +88,4 @@ def format_dict(raw):
return output
if __name__ == '__main__':
main()
sys.exit(main())