| 1204 | } |
| 1205 | |
| 1206 | static char *opt_set_sat(const char *arg, struct amount_sat *sat) |
| 1207 | { |
| 1208 | struct amount_msat msat; |
| 1209 | if (!parse_amount_msat(&msat, arg, strlen(arg))) |
| 1210 | return tal_fmt(NULL, "Unable to parse millisatoshi '%s'", arg); |
| 1211 | if (!amount_msat_to_sat(sat, msat)) |
| 1212 | return tal_fmt(NULL, "'%s' is not a whole number of sats", arg); |
| 1213 | return NULL; |
| 1214 | } |
| 1215 | |
| 1216 | static char *opt_set_sat_nondust(const char *arg, struct amount_sat *sat) |
| 1217 | { |
no test coverage detected