Skip to content

Commit dfc7019

Browse files
committed
Fix crash issue with runPluginCommand
menuName is NULL when called from runPluginCommand Need to get some test coverage on the MenuManager from C++ level
1 parent 650ef89 commit dfc7019

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

PythonScript/src/MenuManager.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -969,7 +969,7 @@ idx_t MenuManager::findMenuCommand(HMENU hParentMenu, const TCHAR *parentMenuNam
969969
}
970970
}
971971
}
972-
else if(0 == _tcsicmp(parentMenuName, menuName))
972+
else if(NULL == menuName || 0 == _tcsicmp(parentMenuName, menuName))
973973
{
974974
TCHAR *context = NULL;
975975
TCHAR *name = _tcstok_s(strBuffer, _T("\t"), &context);

0 commit comments

Comments
 (0)