mirror of
https://github.com/ElementsProject/lightning.git
synced 2026-08-15 12:50:22 +02:00
type_to_string: detect type failure in DEVELOPER mode.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
2736e997f6
commit
1f8564ffae
1 changed files with 3 additions and 0 deletions
|
|
@ -33,6 +33,9 @@ const char *type_to_string_(const tal_t *ctx, const char *typename,
|
|||
break;
|
||||
}
|
||||
}
|
||||
#if DEVELOPER
|
||||
assert(s);
|
||||
#endif
|
||||
if (!s)
|
||||
s = tal_fmt(ctx, "UNKNOWN TYPE %s", typename);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue