MCPcopy Create free account
hub / github.com/ElementsProject/lightning / amount_msat_sub_sat

Function amount_msat_sub_sat

common/amount.c:330–340  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328}
329
330WARN_UNUSED_RESULT bool amount_msat_sub_sat(struct amount_msat *val,
331 struct amount_msat a,
332 struct amount_sat b)
333{
334 struct amount_msat msatb;
335
336 if (!amount_sat_to_msat(&msatb, b))
337 return false;
338
339 return amount_msat_sub(val, a, msatb);
340}
341
342WARN_UNUSED_RESULT bool amount_sat_sub_msat(struct amount_msat *val,
343 struct amount_sat a,

Callers 6

get_room_above_reserveFunction · 0.85
channel_amount_spendableFunction · 0.85
runFunction · 0.85
amount_msat_deduct_satFunction · 0.85
amount_msat_add_sat_s64Function · 0.85

Calls 2

amount_msat_subFunction · 0.85
amount_sat_to_msatFunction · 0.70

Tested by

no test coverage detected