Merge "Only run warn.py's main function if it is the main program." am: 312c310f7c

am: ce4e16d835

Change-Id: I44973ef0f9ff3f8e1bc641db592b1ac3c96d051a
This commit is contained in:
Meike Baumgärtner
2016-09-29 04:11:30 +00:00
committed by android-build-merger

View File

@@ -2342,10 +2342,14 @@ def dump_csv():
print '{},,{}'.format(total, 'All warnings')
##### Main function starts here. #########################
def main():
parse_input_file()
if args.gencsv:
dump_csv()
else:
dump_html()
parse_input_file()
if args.gencsv:
dump_csv()
else:
dump_html()
# Run main function if warn.py is the main program.
if __name__ == '__main__':
main()