diff options
| author | Anna Zaks <ganna@apple.com> | 2015-03-28 02:17:21 +0000 |
|---|---|---|
| committer | Anna Zaks <ganna@apple.com> | 2015-03-28 02:17:21 +0000 |
| commit | 50b0956754ea437b8b4df3a53a1950ab9f987a0d (patch) | |
| tree | 1190334bd4efcbea2da2665942a447d7fde7e240 /clang/tools/scan-build | |
| parent | a0f35592bea616b7d5aace41b64e52b2639db2e5 (diff) | |
| download | bcm5719-llvm-50b0956754ea437b8b4df3a53a1950ab9f987a0d.tar.gz bcm5719-llvm-50b0956754ea437b8b4df3a53a1950ab9f987a0d.zip | |
[scan-build] Be friendly to "" in the argument list.
Do not fail when "" is one of the compilation arguments.
llvm-svn: 233465
Diffstat (limited to 'clang/tools/scan-build')
| -rwxr-xr-x | clang/tools/scan-build/ccc-analyzer | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/tools/scan-build/ccc-analyzer b/clang/tools/scan-build/ccc-analyzer index aa02653a49e..4549b29a806 100755 --- a/clang/tools/scan-build/ccc-analyzer +++ b/clang/tools/scan-build/ccc-analyzer @@ -492,6 +492,11 @@ foreach (my $i = 0; $i < scalar(@ARGV); ++$i) { my $Arg = $ARGV[$i]; my ($ArgKey) = split /=/,$Arg,2; + # Be friendly to "" in the argument list. + if (!defined($ArgKey)) { + next; + } + # Modes ccc-analyzer supports if ($Arg =~ /^-(E|MM?)$/) { $Action = 'preprocess'; } elsif ($Arg eq '-c') { $Action = 'compile'; } |

