After having been compared to a NULL value at symbols.c 763, pointer 'act' is passed as 4th parameter in call to function 'HandleActionDef' at symbols.c 775, where it is dereferenced at action.c 788.
Change-Id: Ib25edc48b26d523fa11a5e99d171750bd768b14d
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
for (unsigned i = 0; i < nActs; i++) {
union xkb_action *toAct = &darray_item(groupi->levels, i).action;
for (unsigned i = 0; i < nActs; i++) {
union xkb_action *toAct = &darray_item(groupi->levels, i).action;
- if (!HandleActionDef(info->ctx, info->actions, &info->mods, act, toAct))
- log_err(info->ctx,
- XKB_ERROR_INVALID_VALUE,
- "Illegal action definition for %s; "
- "Action for group %u/level %u ignored\n",
- KeyInfoText(info, keyi), ndx + 1, i + 1);
+ if (act) {
+ if (!HandleActionDef(info->ctx, info->actions, &info->mods, act, toAct))
+ log_err(info->ctx,
+ "Illegal action definition for %s; "
+ "Action for group %u/level %u ignored\n",
+ KeyInfoText(info, keyi), ndx + 1, i + 1);
- act = (ExprDef *) act->common.next;
+ act = (ExprDef *) act->common.next;
+ }