v2 opens: don't use p2sh inputs for v2 opens

They're not allowed!
This commit is contained in:
niftynei
2022-10-26 15:59:44 -05:00
committed by Rusty Russell
parent 35f12b4ca1
commit 278fa7a0a4
2 changed files with 11 additions and 7 deletions

View File

@@ -1404,6 +1404,9 @@ perform_fundpsbt(struct multifundchannel_command *mfc, u32 feerate)
&mfc_forward_error,
mfc);
json_add_u32(req->js, "minconf", mfc->minconf);
/* If there's any v2 opens, we can't use p2sh inputs */
json_add_bool(req->js, "nonwrapped",
dest_count(mfc, OPEN_CHANNEL) > 0);
}
/* The entire point is to reserve the inputs. */