mirror of
https://github.com/mimblewimble/grin-wallet.git
synced 2025-02-01 08:51:09 +03:00
[Dev] panic in case of invalid kernel_feat_param #PR-564
This commit is contained in:
parent
cbfd09812f
commit
08bd462a99
1 changed files with 4 additions and 5 deletions
|
@ -273,11 +273,10 @@ impl Slate {
|
|||
true => SlateState::Invoice1,
|
||||
false => SlateState::Standard1,
|
||||
};
|
||||
let kernel_features = if kernel_feat_param > 3 {
|
||||
0
|
||||
} else {
|
||||
kernel_feat_param
|
||||
};
|
||||
if kernel_feat_param > 3 {
|
||||
panic!("Invalid value passed as kernel_feat_param to blank_with_kernel_features");
|
||||
}
|
||||
let kernel_features = kernel_feat_param;
|
||||
let is_height_locked =
|
||||
lock_height_param.is_some() && (kernel_features == 2 || kernel_features == 3);
|
||||
let kernel_feat_args = if is_height_locked {
|
||||
|
|
Loading…
Reference in a new issue