mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-20 07:34:24 +01:00
tools/generate-wire.py: simplify printwire routines, fix ... handling.
We make them return bool, and always use names `cursor` and `plen` in callers, for simplicity. Also, `...` means "loop until finished" not "loop this many bytes". Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -14,7 +14,7 @@ int fromwire_peektype(const u8 *cursor UNNEEDED)
|
||||
void printwire_amount_msat(const char *fieldname UNNEEDED, const struct amount_msat *msat UNNEEDED)
|
||||
{ fprintf(stderr, "printwire_amount_msat called!\n"); abort(); }
|
||||
/* Generated stub for printwire_tlvs */
|
||||
void printwire_tlvs(const char *tlv_name UNNEEDED, const u8 **cursor UNNEEDED, size_t *plen UNNEEDED,
|
||||
bool printwire_tlvs(const char *tlv_name UNNEEDED, const u8 **cursor UNNEEDED, size_t *plen UNNEEDED,
|
||||
const struct tlv_print_record_type types[] UNNEEDED, size_t num_types UNNEEDED)
|
||||
{ fprintf(stderr, "printwire_tlvs called!\n"); abort(); }
|
||||
/* Generated stub for printwire_u16 */
|
||||
|
||||
Reference in New Issue
Block a user