projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: filter error path could free invalid ptr
[lttng-tools.git]
/
src
/
lib
/
lttng-ctl
/
filter
/
filter-visitor-generate-bytecode.c
diff --git
a/src/lib/lttng-ctl/filter/filter-visitor-generate-bytecode.c
b/src/lib/lttng-ctl/filter/filter-visitor-generate-bytecode.c
index 7d62757477febbcddd0a88e8f4524d74c74682a9..1cf7cb5c3cf0324048c7d360980564494eb1450e 100644
(file)
--- a/
src/lib/lttng-ctl/filter/filter-visitor-generate-bytecode.c
+++ b/
src/lib/lttng-ctl/filter/filter-visitor-generate-bytecode.c
@@
-520,6
+520,10
@@
int recursive_visit_gen_bytecode(struct filter_parser_ctx *ctx,
LTTNG_HIDDEN
void filter_bytecode_free(struct filter_parser_ctx *ctx)
{
LTTNG_HIDDEN
void filter_bytecode_free(struct filter_parser_ctx *ctx)
{
+ if (!ctx) {
+ return;
+ }
+
if (ctx->bytecode) {
free(ctx->bytecode);
ctx->bytecode = NULL;
if (ctx->bytecode) {
free(ctx->bytecode);
ctx->bytecode = NULL;
This page took
0.039241 seconds
and
4
git commands to generate.