From: Francis Deslauriers Date: Tue, 14 Apr 2020 21:07:23 +0000 (-0400) Subject: bytecode: set register type to `REG_PTR` even if not used X-Git-Url: http://git.efficios.com/?p=deliverable%2Flttng-ust.git;a=commitdiff_plain;h=d312cd3577acb87d606c97dc0dae26499847dac6 bytecode: set register type to `REG_PTR` even if not used There was no need to set the field when using filter as the next instruction would assume that the top of stack is a `REG_PTR`. With the upcoming capture feature, we need to ensure this field is consistent for extraction. Signed-off-by: Francis Deslauriers Signed-off-by: Mathieu Desnoyers Change-Id: I8790618ddde23b29ef2a55698524c45b39ef4793 --- diff --git a/liblttng-ust/lttng-filter-interpreter.c b/liblttng-ust/lttng-filter-interpreter.c index 32610e6c..14f6a464 100644 --- a/liblttng-ust/lttng-filter-interpreter.c +++ b/liblttng-ust/lttng-filter-interpreter.c @@ -456,6 +456,9 @@ static int dynamic_get_index(struct lttng_ctx *ctx, stack_top->u.ptr.field = gid->field; break; } + + stack_top->type = REG_PTR; + return 0; end: