Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f70ef0cb authored by Hans Boehm's avatar Hans Boehm Committed by android-build-merger
Browse files

Merge "Clear more native pointers in finalizers" am: a5ca0ca8 am: 8521a8ff am: 0024c914

am: f58e63b0

* commit 'f58e63b0':
  Clear more native pointers in finalizers

Change-Id: I3e6d6bc03c05b57e4cad96ced7b7f0dfe00b582b
parents 207442e5 f58e63b0
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -163,6 +163,7 @@ public class Camera {
    protected void finalize() throws Throwable {
        try {
            nativeDestructor();
            native_instance = 0;
        } finally {
            super.finalize();
        }
+1 −0
Original line number Diff line number Diff line
@@ -40,6 +40,7 @@ public class ColorFilter {
            super.finalize();
        } finally {
            destroyFilter(native_instance);
            native_instance = 0;
        }
    }

+1 −0
Original line number Diff line number Diff line
@@ -33,6 +33,7 @@ public class DrawFilter {
    protected void finalize() throws Throwable {
        try {
            nativeDestructor(mNativeInt);
            mNativeInt = 0;
        } finally {
            super.finalize();
        }
+2 −1
Original line number Diff line number Diff line
@@ -21,7 +21,7 @@ import java.io.InputStream;
import java.io.FileInputStream;

public class Movie {
    private final long mNativeMovie;
    private long mNativeMovie;

    private Movie(long nativeMovie) {
        if (nativeMovie == 0) {
@@ -82,6 +82,7 @@ public class Movie {
    protected void finalize() throws Throwable {
        try {
            nativeDestructor(mNativeMovie);
            mNativeMovie = 0;
        } finally {
            super.finalize();
        }
+1 −0
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@ public class Rasterizer {

    protected void finalize() throws Throwable {
        finalizer(native_instance);
        native_instance = 0;
    }

    private static native void finalizer(long native_instance);
Loading