wire: move towire/fromwire_amount from wire/ into common/amount.c

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2020-05-15 20:02:02 +09:30
committed by Christian Decker
parent 4dbfce6057
commit 13356b75bf
14 changed files with 92 additions and 74 deletions

View File

@@ -168,4 +168,9 @@ bool parse_amount_msat(struct amount_msat *msat, const char *s, size_t slen);
*/
bool parse_amount_sat(struct amount_sat *sat, const char *s, size_t slen);
/* Marshal/unmarshal functions */
struct amount_msat fromwire_amount_msat(const u8 **cursor, size_t *max);
struct amount_sat fromwire_amount_sat(const u8 **cursor, size_t *max);
void towire_amount_msat(u8 **pptr, const struct amount_msat msat);
void towire_amount_sat(u8 **pptr, const struct amount_sat sat);
#endif /* LIGHTNING_COMMON_AMOUNT_H */