Skip to content

Commit de67425

Browse files
Merge branch 'main' into chr_14546
2 parents 8e2ff1b + 4e0a568 commit de67425

97 files changed

Lines changed: 2201 additions & 1336 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/selfcheck.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ jobs:
121121
122122
- name: Self check (unusedFunction / no test / no gui)
123123
run: |
124-
supprs="--suppress=unusedFunction:lib/errorlogger.h:197 --suppress=unusedFunction:lib/importproject.cpp:1584 --suppress=unusedFunction:lib/importproject.cpp:1608"
124+
supprs="--suppress=unusedFunction:lib/errorlogger.h:197 --suppress=unusedFunction:lib/importproject.cpp:1665 --suppress=unusedFunction:lib/importproject.cpp:1689"
125125
./cppcheck -q --template=selfcheck --error-exitcode=1 --library=cppcheck-lib -D__CPPCHECK__ -D__GNUC__ --enable=unusedFunction,information --exception-handling -rp=. --project=cmake.output.notest_nogui/compile_commands.json --suppressions-list=.selfcheck_unused_suppressions --inline-suppr $supprs
126126
env:
127127
DISABLE_VALUEFLOW: 1

.selfcheck_suppressions

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,46 @@ missingIncludeSystem
33
checkersReport
44

55
# warnings in Qt generated code we cannot fix
6+
funcArgNamesDifferentUnnamed:*/moc_aboutdialog.cpp
7+
funcArgNamesDifferentUnnamed:*/moc_applicationdialog.cpp
8+
funcArgNamesDifferentUnnamed:*/moc_applicationlist.cpp
69
funcArgNamesDifferent:*/moc_checkthread.cpp
10+
funcArgNamesDifferentUnnamed:*/moc_checkthread.cpp
11+
funcArgNamesDifferentUnnamed:*/moc_codeeditor.cpp
712
funcArgNamesDifferent:*/moc_codeeditstylecontrols.cpp
13+
funcArgNamesDifferentUnnamed:*/moc_codeeditstylecontrols.cpp
14+
funcArgNamesDifferentUnnamed:*/moc_compliancereportdialog.cpp
15+
funcArgNamesDifferentUnnamed:*/moc_codeeditstyledialog.cpp
16+
funcArgNamesDifferentUnnamed:*/moc_fileviewdialog.cpp
17+
funcArgNamesDifferentUnnamed:*/moc_helpdialog.cpp
18+
funcArgNamesDifferentUnnamed:*/moc_libraryaddfunctiondialog.cpp
19+
funcArgNamesDifferentUnnamed:*/moc_librarydialog.cpp
20+
funcArgNamesDifferentUnnamed:*/moc_libraryeditargdialog.cpp
21+
funcArgNamesDifferentUnnamed:*/moc_mainwindow.cpp
22+
funcArgNamesDifferentUnnamed:*/moc_newsuppressiondialog.cpp
23+
funcArgNamesDifferentUnnamed:*/moc_platforms.cpp
24+
funcArgNamesDifferentUnnamed:*/moc_projectfile.cpp
25+
funcArgNamesDifferentUnnamed:*/moc_projectfiledialog.cpp
826
funcArgNamesDifferent:*/moc_resultstree.cpp
27+
funcArgNamesDifferentUnnamed:*/moc_resultstree.cpp
928
funcArgNamesDifferent:*/moc_resultsview.cpp
29+
funcArgNamesDifferentUnnamed:*/moc_resultsview.cpp
30+
funcArgNamesDifferentUnnamed:*/moc_scratchpad.cpp
31+
funcArgNamesDifferentUnnamed:*/moc_settingsdialog.cpp
32+
funcArgNamesDifferentUnnamed:*/moc_statsdialog.cpp
33+
funcArgNamesDifferentUnnamed:*/moc_testcppchecklibrarydata.cpp
34+
funcArgNamesDifferentUnnamed:*/moc_testfilelist.cpp
35+
funcArgNamesDifferentUnnamed:*/moc_testprojectfile.cpp
36+
funcArgNamesDifferentUnnamed:*/moc_testresultstree.cpp
37+
funcArgNamesDifferentUnnamed:*/moc_testtranslationhandler.cpp
38+
funcArgNamesDifferentUnnamed:*/moc_testxmlreportv2.cpp
39+
funcArgNamesDifferentUnnamed:*/moc_threaddetails.cpp
1040
funcArgNamesDifferent:*/moc_threadhandler.cpp
41+
funcArgNamesDifferentUnnamed:*/moc_threadhandler.cpp
1142
funcArgNamesDifferent:*/moc_threadresult.cpp
43+
funcArgNamesDifferentUnnamed:*/moc_threadresult.cpp
44+
funcArgNamesDifferentUnnamed:*/moc_translationhandler.cpp
45+
funcArgNamesDifferentUnnamed:*/moc_txtreport.cpp
1246
naming-varname:*/gui/ui_*.h
1347
functionStatic:*/gui/ui_*.h
1448

@@ -37,7 +71,10 @@ invalidPrintfArgType_sint:externals/tinyxml2/tinyxml2.h
3771
naming-privateMemberVariable:externals/tinyxml2/tinyxml2.h
3872
functionStatic:externals/tinyxml2/tinyxml2.cpp
3973
funcArgNamesDifferent:externals/tinyxml2/tinyxml2.cpp
74+
funcArgNamesDifferentUnnamed:externals/tinyxml2/tinyxml2.cpp
75+
funcArgNamesDifferentUnnamed:externals/tinyxml2/tinyxml2.h
4076
nullPointerRedundantCheck:externals/tinyxml2/tinyxml2.cpp
4177
knownConditionTrueFalse:externals/tinyxml2/tinyxml2.cpp
4278
useStlAlgorithm:externals/simplecpp/simplecpp.cpp
79+
funcArgNamesDifferentUnnamed:externals/simplecpp/simplecpp.h
4380
missingMemberCopy:externals/simplecpp/simplecpp.h

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -428,6 +428,7 @@ Vesa Pikki
428428
Ville-Pekka Vahteala
429429
Ville Skyttä
430430
Vincent Le Garrec
431+
Vít Kučera
431432
Vladimir Petrigo
432433
Wang Haoyu
433434
Wang Yang

cfg/selinux.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@
219219
<noreturn>false</noreturn>
220220
<use-retval/>
221221
<leak-ignore/>
222-
<arg nr="1" direction="inout">
222+
<arg nr="1" direction="inout" indirect="1">
223223
<not-uninit/>
224224
<not-null/>
225225
</arg>

cfg/std.cfg

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1665,7 +1665,7 @@
16651665
<returnValue type="int"/>
16661666
<noreturn>false</noreturn>
16671667
<leak-ignore/>
1668-
<arg nr="1" direction="inout">
1668+
<arg nr="1" direction="inout" indirect="1">
16691669
<not-null/>
16701670
<not-uninit/>
16711671
</arg>
@@ -1929,7 +1929,7 @@
19291929
<returnValue type="int"/>
19301930
<noreturn>false</noreturn>
19311931
<leak-ignore/>
1932-
<arg nr="1" direction="inout">
1932+
<arg nr="1" direction="inout" indirect="1">
19331933
<not-null/>
19341934
<not-uninit/>
19351935
</arg>
@@ -2255,7 +2255,7 @@
22552255
<returnValue type="int"/>
22562256
<noreturn>false</noreturn>
22572257
<leak-ignore/>
2258-
<arg nr="1" direction="inout">
2258+
<arg nr="1" direction="inout" indirect="1">
22592259
<not-null/>
22602260
<not-uninit/>
22612261
</arg>

cfg/windows.cfg

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5595,7 +5595,7 @@ HFONT CreateFont(
55955595
<function name="strlwr">
55965596
<returnValue type="char *">arg1</returnValue>
55975597
<noreturn>false</noreturn>
5598-
<arg nr="1" direction="inout">
5598+
<arg nr="1" direction="inout" indirect="1">
55995599
<not-null/>
56005600
<not-uninit/>
56015601
<strz/>
@@ -5963,7 +5963,7 @@ HFONT CreateFont(
59635963
<arg nr="2" direction="out">
59645964
<not-null/>
59655965
</arg>
5966-
<arg nr="3" direction="inout">
5966+
<arg nr="3" direction="inout" indirect="1">
59675967
<not-null/>
59685968
<not-uninit/>
59695969
</arg>
@@ -6009,7 +6009,7 @@ HFONT CreateFont(
60096009
<arg nr="4" direction="out">
60106010
<not-null/>
60116011
</arg>
6012-
<arg nr="5" direction="inout">
6012+
<arg nr="5" direction="inout" indirect="1">
60136013
<not-null/>
60146014
<not-uninit/>
60156015
</arg>

cli/cppcheckexecutor.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,8 @@ int CppCheckExecutor::check(int argc, const char* const argv[])
267267
return EXIT_SUCCESS;
268268
}
269269

270-
Timer realTimeClock("", settings.showtime, nullptr, Timer::Type::OVERALL);
270+
TimerResults overallTimerResults;
271+
Timer realTimeClock("Overall time", settings.showtime, &overallTimerResults, Timer::Type::OVERALL);
271272

272273
settings.loadSummaries();
273274

@@ -276,6 +277,9 @@ int CppCheckExecutor::check(int argc, const char* const argv[])
276277

277278
const int ret = check_wrapper(settings, supprs);
278279

280+
realTimeClock.stop();
281+
overallTimerResults.showResults(settings.showtime, false, true);
282+
279283
return ret;
280284
}
281285

gui/codeeditor.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,9 @@ class CodeEditor : public QPlainTextEdit {
129129
void resizeEvent(QResizeEvent *event) override;
130130

131131
private slots:
132-
void updateLineNumberAreaWidth(int newBlockCount);
132+
void updateLineNumberAreaWidth(int /*newBlockCount*/);
133133
void highlightErrorLine();
134-
void updateLineNumberArea(const QRect & /*rect*/, int /*dy*/);
134+
void updateLineNumberArea(const QRect& rect, int dy);
135135

136136
private:
137137
QString generateStyleString();

0 commit comments

Comments
 (0)