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

Function amount_sat_sub

common/amount.c:288–297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

286}
287
288WARN_UNUSED_RESULT bool amount_sat_sub(struct amount_sat *val,
289 struct amount_sat a,
290 struct amount_sat b)
291{
292 if (a.satoshis < b.satoshis)
293 return false;
294
295 val->satoshis = a.satoshis - b.satoshis;
296 return true;
297}
298
299WARN_UNUSED_RESULT bool amount_msat_sub_sat(struct amount_msat *val,
300 struct amount_msat a,

Callers 15

htlc_txFunction · 0.70
trim_maximum_feerateFunction · 0.50
grind_htlc_tx_feeFunction · 0.50
set_htlc_timeout_feeFunction · 0.50
set_htlc_success_feeFunction · 0.50
tx_to_usFunction · 0.50
inputs_sufficientFunction · 0.50
penalty_tx_createFunction · 0.50
approx_max_feerateFunction · 0.50
htlc_max_possible_sendFunction · 0.50
json_add_channelFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected