Provide human versions of trait interfaces, with a bunch of fixes to make it work
[ldk-java] / src / main / java / org / ldk / structs / NodeInfo.java
index bc45360944282cfc299970df8066c17e5d8d03ea..1916d9ec1e7e3464f38e77b44505c18bf5c33f8d 100644 (file)
@@ -11,7 +11,7 @@ public class NodeInfo extends CommonBase {
        @Override @SuppressWarnings("deprecation")
        protected void finalize() throws Throwable {
                super.finalize();
-               bindings.NodeInfo_free(ptr);
+               if (ptr != 0) { bindings.NodeInfo_free(ptr); }
        }
 
        public void set_channels(long[] val) {