personalize.cpp: avoid length array with value 0

This commit is contained in:
Jacek Jendrzej
2021-11-06 16:37:55 +01:00
parent 373807b158
commit f682ffa8b2

View File

@@ -365,6 +365,8 @@ int CPersonalizeGui::ShowPersonalizationMenu()
} }
CMenuWidget* plMenu = NULL; CMenuWidget* plMenu = NULL;
int pcount = g_Plugins->getNumberOfPlugins(); int pcount = g_Plugins->getNumberOfPlugins();
if (!pcount)
pcount = 1;
std::string pldesc[pcount]; std::string pldesc[pcount];
int pltype[pcount]; int pltype[pcount];
if (show_pluginmenu) if (show_pluginmenu)