From b0efb425ad454e4820d94c971d8dda41c72b5263 Mon Sep 17 00:00:00 2001 From: Tamas Lustyik Date: Sat, 13 Jan 2018 14:40:13 +0100 Subject: [PATCH] Don't forget to exit when parameters are insufficient --- Bridgecraft/main.swift | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Bridgecraft/main.swift b/Bridgecraft/main.swift index 5410ee5..d52ada7 100644 --- a/Bridgecraft/main.swift +++ b/Bridgecraft/main.swift @@ -263,6 +263,7 @@ if CommandLine.arguments.count < 3 { print("Options:") print(" --assume-nonnull Assumes that all headers have been audited for nullability") print("\n") + exit(1) } let origProjectURL = URL(fileURLWithPath: CommandLine.arguments[1]) @@ -319,5 +320,5 @@ do { catch { // clean up cleanUp(projectURL: projectURL, sourceURL: sourceURL, preprocessedURL: preprocessedURL) - exit(1) + exit(2) }