mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 09:21:18 +02:00
avoid null pointer use
This commit is contained in:
@@ -104,7 +104,7 @@ int CCAMMenuHandler::doMainMenu()
|
||||
char name1[255]={0};
|
||||
char str1[255]={0};
|
||||
|
||||
int CiSlots = ca->GetNumberCISlots();
|
||||
int CiSlots = ca ? ca->GetNumberCISlots() : 0;
|
||||
|
||||
CMenuWidget* cammenu = new CMenuWidget(LOCALE_CI_SETTINGS, NEUTRINO_ICON_SETTINGS);
|
||||
cammenu->addIntroItems();
|
||||
@@ -171,7 +171,7 @@ int CCAMMenuHandler::doMainMenu()
|
||||
}
|
||||
|
||||
i = 0;
|
||||
int ScNum = ca->GetNumberSmartCardSlots();
|
||||
int ScNum = ca ? ca->GetNumberSmartCardSlots() : 0;
|
||||
printf("CCAMMenuHandler::doMainMenu sc slots: %d\n", ScNum);
|
||||
|
||||
if(ScNum && CiSlots)
|
||||
|
Reference in New Issue
Block a user