mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 23:24:27 +01:00
tlv: free intermediate messages when they're created
otherwise they'll get cleaned up when the message is free'd. it's nbd either way, but this seems tighter.
This commit is contained in:
committed by
Rusty Russell
parent
4afcc2e5a8
commit
5d8b059ccc
@@ -839,6 +839,7 @@ tlv__type_impl_towire_fields = """\tif ({tlv_name}->{name}) {{
|
||||
\t\tmsg_len = tal_count(tlv_msg);
|
||||
\t\ttowire_u8(p, msg_len);
|
||||
\t\ttowire_u8_array(p, tlv_msg, msg_len);
|
||||
\t\ttal_free(tlv_msg);
|
||||
\t}}
|
||||
"""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user