You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So - I'm using Android Studio 1.5 and Gradle 2.8 and Proguard 5.2.1. My project is running ProGuard settings and stripping things out per the instructions here:
However, what I'm finding is that there is an issue where line 131 of Loader.java opens an InputStream, which isn't ever closed. Here is the stacktrace.
E/StrictMode: A resource was acquired at attached stack trace but never released. See java.io.Closeable for information on avoiding resource leaks.
E/StrictMode: java.lang.Throwable: Explicit termination method 'end' not called
E/StrictMode: at dalvik.system.CloseGuard.open(CloseGuard.java:184)
E/StrictMode: at java.util.zip.Inflater.<init>(Inflater.java:82)
E/StrictMode: at java.util.zip.ZipFile.getInputStream(ZipFile.java:331)
E/StrictMode: at java.util.jar.JarFile.getInputStream(JarFile.java:390)
E/StrictMode: at libcore.net.url.JarURLConnectionImpl.getInputStream(JarURLConnectionImpl.java:222)
E/StrictMode: at java.net.URL.openStream(URL.java:470)
E/StrictMode: at java.lang.ClassLoader.getResourceAsStream(ClassLoader.java:444)
E/StrictMode: at java.lang.Class.getResourceAsStream(Class.java:1412)
E/StrictMode: at org.bytedeco.javacpp.Loader.loadProperties(Loader.java:131)
E/StrictMode: at org.bytedeco.javacpp.Loader.loadProperties(Loader.java:114)
E/StrictMode: at org.bytedeco.javacpp.Loader.load(Loader.java:399)
E/StrictMode: at org.bytedeco.javacv.b.a(FFmpegFrameRecorder.java:91)
E/StrictMode: at org.bytedeco.javacv.b.<clinit>(FFmpegFrameRecorder.java:112)
E/StrictMode: at [myTestAppBundleIDRedacted].onCreate(TestActivity.java:90)
E/StrictMode: at android.app.Activity.performCreate(Activity.java:6374)
E/StrictMode: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1119)
E/StrictMode: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2767)
E/StrictMode: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2879)
E/StrictMode: at android.app.ActivityThread.access$900(ActivityThread.java:182)
E/StrictMode: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1475)
E/StrictMode: at android.os.Handler.dispatchMessage(Handler.java:102)
E/StrictMode: at android.os.Looper.loop(Looper.java:145)
E/StrictMode: at android.app.ActivityThread.main(ActivityThread.java:6141)
E/StrictMode: at java.lang.reflect.Method.invoke(Native Method)
E/StrictMode: at java.lang.reflect.Method.invoke(Method.java:372)
E/StrictMode: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
E/StrictMode: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
Specifically: org.bytedeco.javacpp.Loader.loadProperties(Loader.java:131) : InputStream is = Loader.class.getResourceAsStream(name);
I think the try statement just below this needs a finally clause added to close the stream so that StrictMode doesn't complain that it is never closed. Couldn't this cause a memory leak?
The text was updated successfully, but these errors were encountered:
So - I'm using Android Studio 1.5 and Gradle 2.8 and Proguard 5.2.1. My project is running ProGuard settings and stripping things out per the instructions here:
https://github.com/bytedeco/javacv/wiki/Configuring-Proguard-for-JavaCV
However, what I'm finding is that there is an issue where line 131 of Loader.java opens an InputStream, which isn't ever closed. Here is the stacktrace.
Specifically:
org.bytedeco.javacpp.Loader.loadProperties(Loader.java:131) : InputStream is = Loader.class.getResourceAsStream(name);
I think the try statement just below this needs a finally clause added to close the stream so that StrictMode doesn't complain that it is never closed. Couldn't this cause a memory leak?
The text was updated successfully, but these errors were encountered: