PHP Code:
#include <amxmodx>
public plugin_init()
{
register_clcmd("say /test", "OnSayTest");
}
public OnSayTest(client)
{
new menu = menu_create("Test Menu", "OnMenu");
menu_additem(menu, "Item");
menu_display(client, menu);
return PLUGIN_HANDLED;
}
public OnMenu(client, menu, item)
{
menu_destroy(menu);
return PLUGIN_HANDLED;
}
say /test →
radio1/
radio2/
radio3/open any other menu →
memory leak -
Test Menu is never destroyed.
Any workarounds? Caching menus isn't really an option when using ML or when the menu consists of players. Is it worth filing as a bug report?
__________________