coincontrol: Replace HasInputWeight with returning optional from Get

This commit is contained in:
Andrew Chow committed 2023-12-08 14:55:14 -05:00
1 parent e1abfb5b20
commit 5321786b9d
4 files changed
+17 -36

No files matched your search

+1 -4
View File
@@ -76,10 +76,7 @@ FUZZ_TARGET(coincontrol, .init = initialize_coincontrol)
(void)coin_control.SetInputWeight(out_point, weight);
},
[&] {
// Condition to avoid the assertion in GetInputWeight
if (coin_control.HasInputWeight(out_point)) {
(void)coin_control.GetInputWeight(out_point);
}
(void)coin_control.GetInputWeight(out_point);
});
}
}