summaryrefslogtreecommitdiffstats
path: root/clang/tools/scan-build
Commit message (Collapse)AuthorAgeFilesLines
...
* [analyzer] Prevent ccc/c++-analyzer from hanging on Windows.Anton Yartsev2015-07-012-62/+48
| | | | | | 'fork'+'exec' combination made scan-build and ccc-analyzer hang under Windows. The patch replaces 'fork'+'exec' with more reliable 'system' (ccc-analyzer) and piped 'open' (scan-build). See http://reviews.llvm.org/D8774 and http://reviews.llvm.org/D9357 for more details. llvm-svn: 241201
* [analyzer] Cleanup: $Status is always 0 here.Anton Yartsev2015-06-171-2/+0
| | | | llvm-svn: 239971
* [analyzer] Close file handle before output to file from external command.Anton Yartsev2015-06-171-1/+1
| | | | | | An old code caused problems under Windows - additional temporary file was created for clang preprocessor output while the right output file remained empty. llvm-svn: 239970
* scan-build: Remove useless whitespace in File pathSylvestre Ledru2015-06-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Patch by Honggyu Kim Summary: This patch removes useless whitespace in File path in index.html Previously, a File directory path is copied and pasted as below: arch /arm /kernel /stacktrace.c It just removes the whitespace between directories and makes the copied string as below: arch/arm/kernel/stacktrace.c The output looks same in html format, but the copied directory path can be pasted as it looks. Reviewers: krememek, zaks.anna, sylvestre.ledru Reviewed By: sylvestre.ledru Subscribers: aemerson, cfe-commits Differential Revision: http://reviews.llvm.org/D10354 llvm-svn: 239609
* Revert "[analyzer] scan-build: support spaces in compiler path and arguments."Ahmed Bougacha2015-05-061-5/+1
| | | | | | | | This reverts commit r236423 and its followup r236533, as indiscriminate quoting makes for too much quoting (and clang doesn't like both '"-c"' and -D"FOO=bar"). llvm-svn: 236562
* [analyzer] This eliminates regression caused by r236423.Anton Yartsev2015-05-051-1/+5
| | | | | | Wrap an argument with quotes only if it has spaces. llvm-svn: 236533
* [analyzer] scan-build: support spaces in compiler path and arguments.Anton Yartsev2015-05-041-2/+2
| | | | | | This fixes errors that occur if a path to the default compiler has spaces or if an argument with spaces is given to compiler (e.g. via -I). (http://reviews.llvm.org/D9357) llvm-svn: 236423
* [scan-build] Be friendly to "" in the argument list.Anna Zaks2015-03-281-0/+5
| | | | | | Do not fail when "" is one of the compilation arguments. llvm-svn: 233465
* [analyzer] Change ccc-analyzer to accept both -isystem <path> and -isystem<path>Ted Kremenek2015-02-031-2/+1
| | | | | | Patch by Thomas Hauth! llvm-svn: 227946
* [analyzer] Include a couple more comments on using xcrun to query the SDK.Ted Kremenek2014-12-311-0/+4
| | | | llvm-svn: 225039
* [analyzer] Change ccc-analyzer to mimick behavior on OSX Mavericks/Yosemite ↵Ted Kremenek2014-12-311-0/+20
| | | | | | to automatically infer the SDK location. llvm-svn: 225038
* [analyzer] Eliminated endless loop.Anton Yartsev2014-12-051-0/+1
| | | | llvm-svn: 223426
* [analyzer] Indented code within the DisplayHelp sub.Anton Yartsev2014-11-261-84/+84
| | | | llvm-svn: 222851
* [analyzer] Perl scripts are run differently from makefiles. Sometimes ↵Anton Yartsev2014-10-152-0/+2
| | | | | | additional utilities are involved, e.g. 'env' utility that present in MSYS but is missing in MinGW. The patch unifies launch of "c++-analyzer" and "ccc-analyzer". llvm-svn: 219812
* [analyzer] Handle 'mingw32-make' in the same way as 'make' and 'gmake'.Anton Yartsev2014-10-151-1/+1
| | | | llvm-svn: 219794
* Fix a bug when scan-build is used in a cross-compilation environment withSylvestre Ledru2014-08-081-2/+13
| | | | | | | | | | | | | the --use-cc option. Instead, we will search in the PATH For example: scan-build --use-cc=arm-none-eabi-gcc -o out make -e Initially reported as a Debian Bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=748777 llvm-svn: 215229
* Consistency on the tab/spaceSylvestre Ledru2014-07-171-18/+18
| | | | llvm-svn: 213236
* Fix Bug 14061 - scan-build crashes during postprocessing if BUGFILE no ↵Sylvestre Ledru2014-07-171-0/+4
| | | | | | | | | | longer exists Experienced with Thunderbird build Patch by Matti Niemenmaa llvm-svn: 213235
* Fix typosAlp Toker2014-07-141-1/+1
| | | | | | Also consolidate 'backward compatibility' llvm-svn: 212974
* actually, just check if it is a file (including directory or symlink)Sylvestre Ledru2014-06-161-1/+1
| | | | llvm-svn: 211053
* Check that the directory does not exist.Sylvestre Ledru2014-06-161-0/+6
| | | | | | | | | | | Otherwise, it could allows local users to obtain sensitive information or overwrite arbitrary files via a symlink attack on temporary directories with predictable names. Reported as CVE-2014-2893 ( https://security-tracker.debian.org/tracker/CVE-2014-2893 ) Found by Jakub Wilk llvm-svn: 211051
* List the function/method name in the index page of scan-buildSylvestre Ledru2014-06-141-3/+14
| | | | llvm-svn: 210971
* With the option '-analyzer-config stable-report-filename=true',Sylvestre Ledru2014-06-141-0/+9
| | | | | | | | instead of report-XXXXXX.html, scan-build/clang analyzer generate report-<filename>-<function, method name>-<function position>-<id>.html. (id = i++ for several issues found in the same function/method) llvm-svn: 210970
* revert "r209526 List the function/method name in the index page of scan-build "Sylvestre Ledru2014-05-231-13/+3
| | | | | | Depends on http://reviews.llvm.org/D3762 llvm-svn: 209527
* List the function/method name in the index page of scan-build Sylvestre Ledru2014-05-231-3/+13
| | | | llvm-svn: 209526
* Replace system() by native perl callsSylvestre Ledru2014-05-232-12/+14
| | | | llvm-svn: 209524
* Improve a scan-build messageSylvestre Ledru2014-05-161-1/+5
| | | | llvm-svn: 208951
* [scan-build] Pass --sysroot through for both compilation and linking.Jordan Rose2014-05-121-0/+1
| | | | | | PR19704 llvm-svn: 208595
* scan-build: Don't use realpath when the user provides an explicit path.Jordan Rose2014-04-291-1/+1
| | | | | | PR19583 llvm-svn: 207484
* Handle possible trailing '/' in xcode-select output. Patch by Jeff Olson.Ted Kremenek2014-04-211-1/+1
| | | | llvm-svn: 206752
* [analyzer] scan-build: allow quotes around "-cc1" when looking at -### output.Jordan Rose2014-03-201-1/+1
| | | | | | Third time's the charm. Patch by Brennan Shacklett! llvm-svn: 204362
* [analyzer] scan-build: match whitespace instead of word boundaries around flags.Jordan Rose2014-03-201-1/+1
| | | | | | | | | Because neither ' ' nor '-' is alphanumeric, \b won't match between them! Since in this case we know our output is coming from a -### invocation, we should always have spaces on both sides of the flag we're trying to match, "-cc1". llvm-svn: 204356
* [analyzer] scan-build: when matching flags, make sure the - is the first letter.Jordan Rose2014-03-191-3/+3
| | | | | | PR19191 llvm-svn: 204253
* Add preprocessed output to ccc-analyzer's accepted language map.Ted Kremenek2014-02-251-1/+4
| | | | llvm-svn: 202182
* In some cases (for example, the Firefox build system), the CLANG_CXX ↵Sylvestre Ledru2014-02-181-4/+4
| | | | | | | | | variable is defined but empty. Extend the test (like it is done in scan-build) to check also if the variable is empty or not. llvm-svn: 201586
* Remove trailing spaces (no other change). Bikeshed #2Sylvestre Ledru2014-02-184-73/+70
| | | | llvm-svn: 201584
* Remove trailing spaces (no other change)Sylvestre Ledru2014-02-181-177/+176
| | | | llvm-svn: 201570
* update of the clang version (should probably managed in the configure)Sylvestre Ledru2014-02-111-1/+1
| | | | llvm-svn: 201182
* [analyzer] Strip trailing whitespace characters from input.Anton Yartsev2014-01-231-3/+2
| | | | | | More universal way of removing trailing whitespace characters then 'chomp' does. Chomp "removes any trailing string that corresponds to the current value of $/" (quote from perldoc). In my case an input ended with '\r\r\n', chomp left '\r' at the end of input and the script ended up with an error "Use of uninitialized value in concatenation (.) or string" llvm-svn: 199892
* [analyzer] Files with .c extensions are still C++ files if the compiler is CXX.Jordan Rose2014-01-071-4/+10
| | | | | | PR18339 llvm-svn: 198711
* [analyzer] Add -analyzer-config to scan-build.Jordan Rose2013-12-132-2/+22
| | | | | | | | | -analyzer-config options are now passed from scan-build through to ccc-analyzer and then to clang. Patch by Daniel Connelly! llvm-svn: 197246
* Fix a tranche of comment, test and doc typosAlp Toker2013-12-051-1/+1
| | | | llvm-svn: 196510
* [analyzer] scan-build: Handle -m* option wildcard after compiler/linker flags.Jordan Rose2013-10-221-4/+5
| | | | | | | | | | Some of the shared compiler/linker flags start with -m, so they've been getting passed to the compiler only since r180073. Now, the -m* wildcard is processed after the shared flags and the ignored flags. Found by Laszlo Nagy! llvm-svn: 193184
* [analyzer] scan-build: add missing semicolonJordan Rose2013-09-161-1/+1
| | | | | | Patch by Kevin Zheng! llvm-svn: 190789
* [analyzer] Put more uniqueness in scan-build's temporary directory names.Jordan Rose2013-09-141-3/+11
| | | | | | | | | | | | | | | This is necessary when running two scan-build processes in parallel. The directory naming scheme is now: yyyy-MM-dd-HHmmss-PID-N 2013-09-13-174210-123-1 where "PID" is the scan-build process ID, and "N" is a sequential counter (not likely to be needed now that seconds are mangled in, but just in case). PR17196, using a suggested fix from Greg Czajkowski! llvm-svn: 190735
* scan-build: Set CC and CXX as make variables when wrapping make builds.Jordan Rose2013-08-271-4/+4
| | | | | | | | | Variables set in a makefile are not overridden by environment variables. Make sure we actually override CC and CXX when using scan-build. Patch by Steve McCoy! llvm-svn: 189372
* + make scan-build work with Strawberry Perl, ActiveState Perl, cygwin perl ↵Anton Yartsev2013-08-171-7/+12
| | | | | | and msys perl ports. llvm-svn: 188607
* scan-build: pass -target through to analyzerJordan Rose2013-08-081-0/+1
| | | | llvm-svn: 187989
* [scan-build] Add missing comma to ccc-analyzer.Jordan Rose2013-07-121-1/+1
| | | | | | Thanks, Dmitry! llvm-svn: 186167
* [scan-build] Pass through all -f and -O flags, along with -Wwrite-strings.Jordan Rose2013-07-111-16/+11
| | | | | | | | | | | | | These flags control language options and user-visible macros, so it's important to preserve them when analyzing. Rather than try to keep up with all the -f flags, we'll pass them all through and then ban the ones we don't want (like -fsyntax-only). -Wwrite-strings is really an f-flag in disguise: it implies -fconst-strings. Patch by Keaton Mowry, modified by me. llvm-svn: 186138
OpenPOWER on IntegriCloud