Fix exporting SARIF files from scan-build on Windows.
authorAaron Ballman <aaron@aaronballman.com>
Wed, 24 Jul 2019 20:03:27 +0000 (20:03 +0000)
committerAaron Ballman <aaron@aaronballman.com>
Wed, 24 Jul 2019 20:03:27 +0000 (20:03 +0000)
commit70964d42ea413256b7aa763088a02ba08c6a9087
tree855acf4e1ed4b48afaabd0db83ca34fb69d31fbe
parentff4b515a77880b3a0d7010287b2116f2f3b4db1d
Fix exporting SARIF files from scan-build on Windows.

In Perl, -z is defined as checking if a "file has zero size" and makes no mention what it does when given a directory. It looks like the behavior differs across platforms, which is why on Windows the SARIF file was always being deleted.

Patch by Joe Ranieri.

llvm-svn: 366941
clang/tools/scan-build/libexec/ccc-analyzer