Avoid UB in Tokenizer::printDebugOutput in case of empty tokenlist (see #6913)
This commit is contained in:
parent
fc19c6ca11
commit
95658030bc
|
@ -3799,7 +3799,7 @@ void Tokenizer::printDebugOutput(unsigned int simplification) const
|
||||||
const bool debug = (simplification != 1U && _settings->debug) ||
|
const bool debug = (simplification != 1U && _settings->debug) ||
|
||||||
(simplification != 2U && _settings->debugnormal);
|
(simplification != 2U && _settings->debugnormal);
|
||||||
|
|
||||||
if (debug) {
|
if (debug && list.front()) {
|
||||||
list.front()->printOut(0, list.getFiles());
|
list.front()->printOut(0, list.getFiles());
|
||||||
|
|
||||||
if (_settings->_xml)
|
if (_settings->_xml)
|
||||||
|
|
Loading…
Reference in New Issue