Added error message for unrecognized options.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49092 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/utils/scan-build b/utils/scan-build
index 5600b05..b3cb932 100755
--- a/utils/scan-build
+++ b/utils/scan-build
@@ -239,7 +239,7 @@
shift @ARGV;
if (!@ARGV) {
- die "'-o' option requires a target directory name.";
+ die "$Prog: '-o' option requires a target directory name.\n";
}
$HtmlDir = shift @ARGV;
@@ -258,6 +258,8 @@
next;
}
+ die "$Prog: unrecognized option '$arg'\n" if ($arg =~ /^-/);
+
last;
}