[Java] Update auto-generated Java structs
[ldk-java] / src / main / java / org / ldk / structs / APIError.java
index 76a48e2321aad6b1d4501e331feea38249ac7db8..ac94c9ce3ee5d9607ce9543fad480498ff38d8fd 100644 (file)
@@ -134,7 +134,7 @@ public class APIError extends CommonBase {
                        super(null, ptr);
                        long script = obj.script;
                        org.ldk.structs.ShutdownScript script_hu_conv = null; if (script < 0 || script > 4096) { script_hu_conv = new org.ldk.structs.ShutdownScript(null, script); }
-                       script_hu_conv.ptrs_to.add(this);
+                       if (script_hu_conv != null) { script_hu_conv.ptrs_to.add(this); };
                        this.script = script_hu_conv;
                }
        }
@@ -152,7 +152,7 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(this);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(this);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(this); };
                return ret_hu_conv;
        }
 
@@ -164,7 +164,7 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(err);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
                return ret_hu_conv;
        }
 
@@ -177,7 +177,7 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(feerate);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
                return ret_hu_conv;
        }
 
@@ -189,7 +189,7 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(err);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
                return ret_hu_conv;
        }
 
@@ -201,7 +201,7 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(err);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
                return ret_hu_conv;
        }
 
@@ -212,7 +212,7 @@ public class APIError extends CommonBase {
                long ret = bindings.APIError_monitor_update_failed();
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
                return ret_hu_conv;
        }
 
@@ -224,8 +224,8 @@ public class APIError extends CommonBase {
                Reference.reachabilityFence(script);
                if (ret >= 0 && ret <= 4096) { return null; }
                org.ldk.structs.APIError ret_hu_conv = org.ldk.structs.APIError.constr_from_ptr(ret);
-               ret_hu_conv.ptrs_to.add(ret_hu_conv);
-               ret_hu_conv.ptrs_to.add(script);
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
+               if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(script); };
                return ret_hu_conv;
        }