diff --git a/CHANGES b/CHANGES index 33b4066ef2..fc2e063b75 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,9 @@ +7.1.0-dev.478 | 2024-11-08 18:36:07 +0100 + + * Fixed ZAM memory leak when coercing values to "any" (Vern Paxson, Corelight) + + * ci: Remove -b from test_script lines for zam tasks (Arne Welzel, Corelight) + 7.1.0-dev.475 | 2024-11-08 15:35:00 +0100 * fixes for ZAM's propagation of control flow information for some degenerate constructs (Vern Paxson, Corelight) diff --git a/VERSION b/VERSION index 341098f976..9c05caa52d 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -7.1.0-dev.475 +7.1.0-dev.478 diff --git a/src/script_opt/ZAM/OPs/coercions.op b/src/script_opt/ZAM/OPs/coercions.op index fef6ea8096..9f9af52ebd 100644 --- a/src/script_opt/ZAM/OPs/coercions.op +++ b/src/script_opt/ZAM/OPs/coercions.op @@ -128,7 +128,9 @@ eval if ( $1->Size() > 0 ) unary-expr-op To-Any-Coerce op-type X set-type $1 -eval AssignTarget($$, ZVal($1.ToVal(Z_TYPE), ZAM::any_base_type)) +eval auto orig_lhs = $$; /* hold in case $$ = $1 */ + $$ = ZVal($1.ToVal(Z_TYPE), ZAM::any_base_type); + ZVal::DeleteManagedType(orig_lhs); unary-expr-op From-Any-Coerce no-const