Skip to content

Commit 906389e

Browse files
committed
Merge pull request #1655 from bettio/fix-pr1650
Add missing `context_destroy` in error handling These changes are made under both the "Apache 2.0" and the "GNU Lesser General Public License 2.1 or later" license terms (dual license). SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later
2 parents e4984ce + 67be849 commit 906389e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/libAtomVM/nifs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1232,6 +1232,7 @@ static term do_spawn(Context *ctx, Context *new_ctx, size_t arity, size_t n_free
12321232
valid_request = true;
12331233
group_leader = term_get_tuple_element(request_term, 3);
12341234
} else {
1235+
context_destroy(new_ctx);
12351236
RAISE_ERROR(BADARG_ATOM);
12361237
}
12371238

0 commit comments

Comments
 (0)