Skip to content

Commit

Permalink
filterx: support message_value in subscript and attr key and value
Browse files Browse the repository at this point in the history
Signed-off-by: Attila Szakacs <[email protected]>
  • Loading branch information
alltilla committed Aug 1, 2024
1 parent d92f754 commit fae09ec
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/filterx/expr-get-subscript.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ _eval(FilterXExpr *s)
if (!variable)
return NULL;

FilterXObject *key = filterx_expr_eval_typed(self->key);
FilterXObject *key = filterx_expr_eval(self->key);
if (!key)
goto exit;
result = filterx_object_get_subscript(variable, key);
Expand Down
4 changes: 2 additions & 2 deletions lib/filterx/expr-literal-generator.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,12 @@ _eval_elements(FilterXObject *fillable, GList *elements)
FilterXObject *key = NULL;
if (elem->key)
{
key = filterx_expr_eval_typed(elem->key);
key = filterx_expr_eval(elem->key);
if (!key)
return FALSE;
}

FilterXObject *value = filterx_expr_eval_typed(elem->value);
FilterXObject *value = filterx_expr_eval(elem->value);
if (!value)
{
filterx_object_unref(key);
Expand Down
4 changes: 2 additions & 2 deletions lib/filterx/expr-set-subscript.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ _eval(FilterXExpr *s)

if (self->key)
{
key = filterx_expr_eval_typed(self->key);
key = filterx_expr_eval(self->key);
if (!key)
goto exit;
}
Expand All @@ -62,7 +62,7 @@ _eval(FilterXExpr *s)
goto exit;
}

new_value = filterx_expr_eval_typed(self->new_value);
new_value = filterx_expr_eval(self->new_value);
if (!new_value)
goto exit;

Expand Down
2 changes: 1 addition & 1 deletion lib/filterx/expr-setattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ _eval(FilterXExpr *s)
goto exit;
}

FilterXObject *new_value = filterx_expr_eval_typed(self->new_value);
FilterXObject *new_value = filterx_expr_eval(self->new_value);
if (!new_value)
goto exit;

Expand Down

0 comments on commit fae09ec

Please sign in to comment.