Skip to content

Commit

Permalink
cppcheck: Fix "known condition warning" in networkcontrol.cpp.
Browse files Browse the repository at this point in the history
This warning used to be necessary as the code formerly used a
dynamic_cast to convert types. Switching to a simple assignment since
the code was casting to a parent type removed the need for this
validity test.
  • Loading branch information
linuxdude42 committed Oct 2, 2020
1 parent 041b216 commit 4b0c14c
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions mythtv/programs/mythfrontend/networkcontrol.cpp
Expand Up @@ -1201,8 +1201,6 @@ QString NetworkControl::processTheme( NetworkCommand* nc)
return QString("ERROR: no top screen found!");

MythUIType *currType = topScreen;
if (currType == nullptr)
return QString("ERROR: cannot cast top screen!");

while (!path.isEmpty())
{
Expand Down

0 comments on commit 4b0c14c

Please sign in to comment.