X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Forg%2Fldk%2Fstructs%2FQueryChannelRange.java;h=c1a8b3f2ca970a5cafa05bf97034d90d750fde79;hb=2ed9081562d00a8645604b07629e963231d49e0f;hp=70491a4d811cabde069bbb0136e1bf59c30a2a3a;hpb=166ff04616cfee975ce991607ca0df88857193df;p=ldk-java diff --git a/src/main/java/org/ldk/structs/QueryChannelRange.java b/src/main/java/org/ldk/structs/QueryChannelRange.java index 70491a4d..c1a8b3f2 100644 --- a/src/main/java/org/ldk/structs/QueryChannelRange.java +++ b/src/main/java/org/ldk/structs/QueryChannelRange.java @@ -11,40 +11,40 @@ public class QueryChannelRange extends CommonBase { } public QueryChannelRange(QueryChannelRange orig) { - super(bindings.QueryChannelRange_clone(orig.ptr & ~1)); + super(bindings.QueryChannelRange_clone(orig == null ? 0 : orig.ptr & ~1)); this.ptrs_to.add(orig); } public byte[] get_chain_hash(QueryChannelRange this_ptr) { - byte[] ret = bindings.QueryChannelRange_get_chain_hash(this_ptr.ptr & ~1); + byte[] ret = bindings.QueryChannelRange_get_chain_hash(this_ptr == null ? 0 : this_ptr.ptr & ~1); this.ptrs_to.add(this_ptr); return ret; } public void set_chain_hash(QueryChannelRange this_ptr, byte[] val) { - bindings.QueryChannelRange_set_chain_hash(this_ptr.ptr & ~1, val); + bindings.QueryChannelRange_set_chain_hash(this_ptr == null ? 0 : this_ptr.ptr & ~1, val); this.ptrs_to.add(this_ptr); } public int get_first_blocknum(QueryChannelRange this_ptr) { - int ret = bindings.QueryChannelRange_get_first_blocknum(this_ptr.ptr & ~1); + int ret = bindings.QueryChannelRange_get_first_blocknum(this_ptr == null ? 0 : this_ptr.ptr & ~1); this.ptrs_to.add(this_ptr); return ret; } public void set_first_blocknum(QueryChannelRange this_ptr, int val) { - bindings.QueryChannelRange_set_first_blocknum(this_ptr.ptr & ~1, val); + bindings.QueryChannelRange_set_first_blocknum(this_ptr == null ? 0 : this_ptr.ptr & ~1, val); this.ptrs_to.add(this_ptr); } public int get_number_of_blocks(QueryChannelRange this_ptr) { - int ret = bindings.QueryChannelRange_get_number_of_blocks(this_ptr.ptr & ~1); + int ret = bindings.QueryChannelRange_get_number_of_blocks(this_ptr == null ? 0 : this_ptr.ptr & ~1); this.ptrs_to.add(this_ptr); return ret; } public void set_number_of_blocks(QueryChannelRange this_ptr, int val) { - bindings.QueryChannelRange_set_number_of_blocks(this_ptr.ptr & ~1, val); + bindings.QueryChannelRange_set_number_of_blocks(this_ptr == null ? 0 : this_ptr.ptr & ~1, val); this.ptrs_to.add(this_ptr); }