Skip to content

Coverity fixes

Fixes the following from Kurt Hindenburg's email:

> ** CID 345002:  Incorrect expression  (USELESS_CALL)
> 
> 
> ________________________________________________________________________________________________________
> *** CID 345002:  Incorrect expression  (USELESS_CALL)
> /home/kurthindenburg/Devel/KDE/src/konsole/src/cov-int/src/konsoleprivate_autogen/DRAQINE3W2/moc_TerminalDisplay.cpp: 347 in Konsole::TerminalDisplay::qt_static_metacall(QObject *, QMetaObject::Call, int, void **)()
> 341             case 29: _t->outputSuspended((*reinterpret_cast< bool(*)>(_a[1]))); break;
> 342             case 30: _t->setUsesMouseTracking((*reinterpret_cast< bool(*)>(_a[1]))); break;
> 343             case 31: _t->setBracketedPasteMode((*reinterpret_cast< bool(*)>(_a[1]))); break;
> 344             case 32: _t->bell((*reinterpret_cast< const QString(*)>(_a[1]))); break;
> 345             case 33: _t->setMargin((*reinterpret_cast< int(*)>(_a[1]))); break;
> 346             case 34: _t->setCenterContents((*reinterpret_cast< bool(*)>(_a[1]))); break;
>>>>   CID 345002:  Incorrect expression  (USELESS_CALL)
>>>>   Calling "_t->colorScheme()" is only useful for its return value, which is ignored.
> 347             case 35: _t->colorScheme(); break;
> 348             case 36: { Qt::Edge _r = _t->droppedEdge();
> 349                 if (_a[0]) *reinterpret_cast< Qt::Edge*>(_a[0]) = std::move(_r); }  break;
> 350             case 37: _t->updateReadOnlyState((*reinterpret_cast< bool(*)>(_a[1]))); break;
> 351             case 38: { IncrementalSearchBar* _r = _t->searchBar();
> 352                 if (_a[0]) *reinterpret_cast< IncrementalSearchBar**>(_a[0]) = std::move(_r); }  break;

[...snip...]

> ** CID 344999:  Uninitialized members  (UNINIT_CTOR)
> /home/kurthindenburg/Devel/KDE/src/konsole/src/Screen.h: 758 in Konsole::Screen::SavedState::SavedState()()
> 
> 
> ________________________________________________________________________________________________________
> *** CID 344999:  Uninitialized members  (UNINIT_CTOR)
> /home/kurthindenburg/Devel/KDE/src/konsole/src/Screen.h: 758 in Konsole::Screen::SavedState::SavedState()()
> 752                 : cursorColumn(0)
> 753                 , cursorLine(0)
> 754                 , rendition(0)
> 755                 , foreground(CharacterColor())
> 756                 , background(CharacterColor())
> 757             {
>>>>   CID 344999:  Uninitialized members  (UNINIT_CTOR)
>>>>   Non-static class member "originMode" is not initialized in this constructor nor in any functions that it calls.
> 758             }
> 759     
> 760             int cursorColumn;
> 761             int cursorLine;
> 762             int originMode;
> 763             RenditionFlags rendition;
> 

Merge request reports