X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=sidebyside;f=src%2Fmain%2Fjava%2Forg%2Fldk%2Fstructs%2FChannelHandshakeConfig.java;h=e4b3e944ffe9afbb5e4042e99bc7a647844d03d0;hb=c6bac88847b7c09560af81f00ba8dd3c2ebe3a19;hp=8f9fb17b34b3de5b8107e2fec8fa3bcfe1da4d9b;hpb=0d48e557e83ef085cc92c2de63b9c81c061ce78c;p=ldk-java diff --git a/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java b/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java index 8f9fb17b..e4b3e944 100644 --- a/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java +++ b/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java @@ -119,8 +119,8 @@ public class ChannelHandshakeConfig extends CommonBase { */ public static ChannelHandshakeConfig of(int minimum_depth_arg, short our_to_self_delay_arg, long our_htlc_minimum_msat_arg) { long ret = bindings.ChannelHandshakeConfig_new(minimum_depth_arg, our_to_self_delay_arg, our_htlc_minimum_msat_arg); - if (ret >= 0 && ret < 1024) { return null; } - ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + if (ret >= 0 && ret <= 4096) { return null; } + ChannelHandshakeConfig ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new ChannelHandshakeConfig(null, ret); } ret_hu_conv.ptrs_to.add(ret_hu_conv); return ret_hu_conv; } @@ -130,8 +130,8 @@ public class ChannelHandshakeConfig extends CommonBase { */ public ChannelHandshakeConfig clone() { long ret = bindings.ChannelHandshakeConfig_clone(this.ptr); - if (ret >= 0 && ret < 1024) { return null; } - ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + if (ret >= 0 && ret <= 4096) { return null; } + ChannelHandshakeConfig ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new ChannelHandshakeConfig(null, ret); } ret_hu_conv.ptrs_to.add(this); return ret_hu_conv; } @@ -141,8 +141,8 @@ public class ChannelHandshakeConfig extends CommonBase { */ public static ChannelHandshakeConfig with_default() { long ret = bindings.ChannelHandshakeConfig_default(); - if (ret >= 0 && ret < 1024) { return null; } - ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + if (ret >= 0 && ret <= 4096) { return null; } + ChannelHandshakeConfig ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new ChannelHandshakeConfig(null, ret); } ret_hu_conv.ptrs_to.add(ret_hu_conv); return ret_hu_conv; }