| 1213 | } |
| 1214 | |
| 1215 | static char *opt_set_sat(const char *arg, struct amount_sat *sat) |
| 1216 | { |
| 1217 | struct amount_msat msat; |
| 1218 | if (!parse_amount_msat(&msat, arg, strlen(arg))) |
| 1219 | return tal_fmt(NULL, "Unable to parse millisatoshi '%s'", arg); |
| 1220 | if (!amount_msat_to_sat(sat, msat)) |
| 1221 | return tal_fmt(NULL, "'%s' is not a whole number of sats", arg); |
| 1222 | return NULL; |
| 1223 | } |
| 1224 | |
| 1225 | static char *opt_set_sat_nondust(const char *arg, struct amount_sat *sat) |
| 1226 | { |
no test coverage detected