Skip to content

Commit

Permalink
NodeValue.CodeBlock: fix memory leak in info
Browse files Browse the repository at this point in the history
  • Loading branch information
kivikakk committed Dec 6, 2021
1 parent 38b8abc commit 1dc5efe
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/nodes.zig
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ pub const NodeValue = union(enum) {
allocator.free(content);
},
.CodeBlock => |ncb| {
if (ncb.info) |info| {
allocator.free(info);
}
ncb.literal.deinit();
},
.HtmlBlock => |nhb| {
Expand Down

0 comments on commit 1dc5efe

Please sign in to comment.