Commit Graph

19760 Commits

Author SHA1 Message Date
Sebastian a410cea59a
Donate CPU: Collect information messages and provide checkLibrary reports (#1610)
Related trac ticket: https://trac.cppcheck.net/ticket/8947
Enable information messages and "--check-library" in the Cppcheck
parameters.
Store the information messages and the rest of the messages in different
variables and upload them separately.
The server stores the information messages in a sub-directory similarly
to the normal issue messages in one file per package.
Reports for "checkLibraryFunction" and "checkLibraryNoReturn" message ids
are generated by the server now.
2019-01-22 15:27:13 +01:00
orbitcowboy 6b61866d59 wxwidgets.cfg: Improved support for wxFileDialog functions. 2019-01-22 08:36:37 +01:00
Sebastian 72c9646be9
misra.py: Possible fix for problematic code (#1613)
Without the `for scope in data.scopes:` loop, scope is not assigned anything.
From the context a loop over `data.scopes` could be intended. But other things like indentation would be possibly correct too. Not sure how this code should be.
We try this fix.
2019-01-22 07:28:29 +01:00
Daniel Marjamäki 149d688e9a Fix return value from ErrorLogger::reportUnmatchedSuppressions 2019-01-22 06:45:22 +01:00
versat 6f62b83fe6 checkcfg: Add regression test for umatchedSuppression errors
As discussed in https://trac.cppcheck.net/ticket/8931 a regression test is added
to the test/cfg/runtests.sh script to make sure that unmatchedSuppression messages result in an Cppcheck exit code that signals a failure.
2019-01-21 20:53:13 +01:00
Daniel Marjamäki 4119cfd3d1 Correct exit code when there are no unmatched suppressions 2019-01-21 20:33:22 +01:00
Paul Fultz II 4b37f276c2 ValueFlow: Set arrays to true when converting to a boolean
This sets it by checking the parent. It doesn't handle function parameters yet.
2019-01-21 20:05:35 +01:00
orbitcowboy 63660fcc2b wxwidgets.cfg: Improved support for more constants from wx/defs.h 2019-01-21 17:14:53 +01:00
orbitcowboy 030ab66e4d wxwidgets.cfg: Added support for wxGrid::DrawTextRectangle() 2019-01-21 16:33:07 +01:00
orbitcowboy 84d80909b0 wxwidgets.cfg: Added support for wxGrid::MakeCellVisible(int row, int col). 2019-01-21 16:25:29 +01:00
orbitcowboy ce254fe3a5 wxwidgets.cfg: Added support for macros from wx/html/htmlwin.h 2019-01-21 11:02:03 +01:00
orbitcowboy d1c4c7d214 wxwidgets.cfg: Improved support for wxWidgets constants. 2019-01-21 10:53:24 +01:00
orbitcowboy 7bc776abea wxwidgets.cfg: Improved support for wxWidgets macros and constants. 2019-01-21 10:50:42 +01:00
Daniel Marjamäki 91435310cb Fixed #8925 (compile_commands.json: False positives in .mm (Objective-C++) files, that file type should maybe just be ignored) 2019-01-21 06:36:31 +01:00
Daniel Marjamäki a26287f491 Fix Token::findExpressionStartEndTokens() regression 2019-01-20 13:23:19 +01:00
Daniel Marjamäki 8da4e31c42 Fixed #8941 (False Positive: Variable 'f' is assigned a value that is never used.) 2019-01-20 13:20:23 +01:00
Daniel Marjamäki 0f19dfea82 Do not check unmatched suppressions in --check-library checking 2019-01-20 10:30:38 +01:00
rikardfalkeborn f7d85e9df2 Add regression test for #6904 (#1611)
Ticket #6904 was fixed in 34dbc3c00c.
Add a regression test to make sure it doesn't reappear.
2019-01-20 10:05:09 +01:00
Daniel Marjamäki 0945e827c6 Fixed #8931 (Missing error exitcode when an unmatched suppression is detected) 2019-01-19 21:42:01 +01:00
versat dfaba30290 donate-cpu.py: Fix possible usage of none type variable
"bandwidth_limit" is None by default and therefore can not be used for string
concatenation in this case.
2019-01-19 12:45:08 +01:00
Sebastian e3db99a16e
donate-cpu.py: Add option for limiting bandwidth (#1606)
With this new option it is possible to limit the download rate / bandwidth that wget uses to download packages.
The value is verified by running wget with it and check if there is a parse error (exit code 2). If the value is not valid an error message is shown and the script exits with an error code.
2019-01-18 21:36:03 +01:00
Sebastian c106dd2939
misra addon: Fix issue with unexpected encodings in loadRuleTexts() (trac 8946) (#1608)
https://trac.cppcheck.net/ticket/8946
Add tests to travis script for verifying rule text loading.
Add dummy rule text files.
misra.py: Try to find a suitable codec for rule texts file.
2019-01-18 21:30:08 +01:00
Paul Fultz II 9e4b605fca Properly find pcre (#1607) 2019-01-18 21:13:35 +01:00
IOBYTE 1acbdde302 Fixed #7417 ("syntax error" in valid code containing explicitly specialised variable template) (#1604) 2019-01-18 21:12:39 +01:00
Sebastian 4b1544d33b
library.cpp: Let tinyxml2 print a helpful error message when XML is bad (#1609)
In case the XML code of a library configuration is invalid Cppcheck now additionally prints out some helpful error description like this:
"Error=XML_ERROR_MISMATCHED_ELEMENT ErrorID=16 (0x10) Line number=304: XMLElement name=noreturn"
2019-01-18 17:10:41 +01:00
orbitcowboy 80a6d7c390 wxwidgets.cfg: Improved support for some wxGrid functions. 2019-01-18 16:03:20 +01:00
orbitcowboy 204db723e3 wxwidgets.cfg: Reordered entries: 1) Macros 2) POD-types and 3) Function defintions. 2019-01-18 15:54:37 +01:00
orbitcowboy 2ae9ba60bf wxwidgets.cfg: Added support for wxDC:DrawBitmap(). 2019-01-18 15:51:30 +01:00
orbitcowboy bbc2bcb7a8 wxwidgets.cfg: Improved support for macros from wx/property.h 2019-01-17 16:58:12 +01:00
orbitcowboy bdad1a3e3f wxwidgets.cfg: Added support for wxGrid::SetCellValue() 2019-01-17 16:41:20 +01:00
orbitcowboy ec592032a1 wxwidgets.cfg: Improved support for functions and macros from wxPGProperty. 2019-01-17 16:32:26 +01:00
versat be14517bcd donate-cpu.py: Fix too few return values in scanPackage()
In case a crash is detected the scanPackage() function returns too few values (three instead of four).
This likely leads to an exception then.
2019-01-17 14:58:15 +01:00
orbitcowboy cdae767bd8 windows.cfg: Added support for some constants from WinBase.h 2019-01-16 15:54:18 +01:00
orbitcowboy 705fa1820c windows.cfg: Added support for some constants from winnt.h and WinBase.h 2019-01-16 15:51:14 +01:00
orbitcowboy 11cf28e6ab wxwidgets.cfg: Improved support for wxArrayString functions. 2019-01-16 15:11:27 +01:00
orbitcowboy 347e3a121a wxwidgets.cfg: Added support for wxArrayString::push_back(). 2019-01-16 15:05:10 +01:00
orbitcowboy 270bceb1b6 windows.cfg: Added support for some return flags from GetHandleInformation(), ref.: https://msdn.microsoft.com/en-us/library/ms724329%28v=vs.85%29.aspx 2019-01-16 14:53:02 +01:00
orbitcowboy 6b16709b92 wxwidgets.cfg: Added support for wxTextCtrl::SetValue(). 2019-01-16 12:01:56 +01:00
orbitcowboy 061ee3e886 wxwidgets.cfg: Added support for wxButton::Enable(). 2019-01-16 10:56:47 +01:00
orbitcowboy 050fd0a64c wxwidgets.cfg: Added support for wxGrid::DrawTextRectangle(). 2019-01-16 10:49:03 +01:00
orbitcowboy cd2ac71e71 wxwidgets.cfg: Added support for wxConfigBase::Write() and wxConfigBase::Read(). 2019-01-16 09:52:24 +01:00
orbitcowboy 34f1fb6501 wxwdigets.cfg: Improved support for some wxString function. 2019-01-15 15:56:43 +01:00
Sebastian 7281a886e2
donate-cpu-server.py: Enhance formatting of latest.html output (#1605)
Column width can now be easily changed via the `column_width` array.
Increased column width for the packages column so it is more likely that the date is not dropped.
Increased the column width for the number of results since there are packages which have about 100000 results.
2019-01-15 11:39:47 +01:00
Lauri Nurmi a7a0a54557 Show a clear button in the Quick Filter text field in GUI. (#1603) 2019-01-15 10:35:23 +01:00
Lauri Nurmi 3bbd9fc9a4 Replace "virtual method" with "virtual function" in messages.
The term "method" is not really a part of C++ terminology.
2019-01-15 06:22:14 +01:00
Lauri Nurmi f267900257 Fix spelling of "overridden" in function names.
One 'd' was missing.
2019-01-15 06:22:14 +01:00
Robert Reif 6ef8dad459 template simplifier: improve namespace matching
* out of line member functions are a namespace
* template<...> and *_cast<> can't be instantiations
* refactor code to use less function parameters
* fix instantiation scopes
* use full name with namespace when available
* fallback to just matching names when full name doesn't match
2019-01-14 21:32:58 +01:00
Sebastian 37f2aa0e2d
triage tool: Add "Load from clipboard" functionality (#1599)
The user now can choose to "Load from file" or "Load from clipboard".
readme.txt has been adapted.
2019-01-14 17:49:10 +01:00
Sebastian aa40e374ac
test/cfg/runtests.sh: Qt test: Fix syntax check when "-fPIC" is required (#1600)
On linux systems (like travis) Qt often seems to be built with the option "reduce_relocations" which requires an application using it to specify the option "-fPIC".
2019-01-14 17:48:04 +01:00
IOBYTE f0cfe03f7b template simplifier: add cli --debug-template option to print the parsed template information (#1598) 2019-01-14 08:29:32 +01:00