Make scan-build process of --use-cc and --html-title more robust.

llvm-svn: 71567
This commit is contained in:
Ted Kremenek 2009-05-12 18:04:43 +00:00
parent 5a4d12afbf
commit 3c2775f0b0
1 changed files with 3 additions and 3 deletions

View File

@ -1067,7 +1067,7 @@ while (@ARGV) {
if ($arg =~ /^--html-title(=(.+))?$/) {
shift @ARGV;
if ($2 eq '') {
if (!defined $2 || $2 eq '') {
if (!@ARGV) {
DieDiag("'--html-title' option requires a string.\n");
}
@ -1090,7 +1090,7 @@ while (@ARGV) {
shift @ARGV;
my $cc;
if ($2 eq "") {
if (!defined $2 || $2 eq "") {
if (!@ARGV) {
DieDiag("'--use-cc' option requires a compiler executable name.\n");
}
@ -1107,7 +1107,7 @@ while (@ARGV) {
if ($arg =~ /^--use-c\+\+(=(.+))?$/) {
shift @ARGV;
if ($2 eq "") {
if (!defined $2 || $2 eq "") {
if (!@ARGV) {
DieDiag("'--use-c++' option requires a compiler executable name.\n");
}