elm_dbus_menu: add null checking after memory allocation