[cairo-commit] cairo-java/src/java/org/freedesktop/cairo
TextExtents.java, 1.1, 1.2
Jeffrey Morgan
commit at pdx.freedesktop.org
Mon Mar 14 08:24:08 PST 2005
Committed by: kuzman
Update of /cvs/cairo/cairo-java/src/java/org/freedesktop/cairo
In directory gabe:/tmp/cvs-serv705/src/java/org/freedesktop/cairo
Modified Files:
TextExtents.java
Log Message:
Fixed allocation of TextExtents and free memory.
Index: TextExtents.java
===================================================================
RCS file: /cvs/cairo/cairo-java/src/java/org/freedesktop/cairo/TextExtents.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- TextExtents.java 23 Feb 2005 18:17:52 -0000 1.1
+++ TextExtents.java 14 Mar 2005 16:24:06 -0000 1.2
@@ -41,6 +41,11 @@
return get_y_advance(getHandle());
}
+ protected void finalize() throws Throwable {
+ free(getHandle());
+ super.finalize();
+ }
+
/*
* Native calls
*/
@@ -50,4 +55,5 @@
native static final private double get_height(Handle obj);
native static final private double get_x_advance(Handle obj);
native static final private double get_y_advance(Handle obj);
+ native static final private void free(Handle obj);
}
More information about the cairo-commit
mailing list