我正在使用Strict模式,并且遇到了很多错误。
E/StrictMode: A resource was acquired at attached stack trace but never released. See java.io.Closeable for information on avoiding resource leaks.
java.lang.Throwable: Explicit termination method 'close' not called
at dalvik.system.CloseGuard.open(CloseGuard.java:180)
at java.io.FileOutputStream.<init>(FileOutputStream.java:222)
at android.app.ContextImpl.openFileOutput(ContextImpl.java:514)
at android.content.ContextWrapper.openFileOutput(ContextWrapper.java:199)
at bjq.a(:com.google.android.gms.DynamiteModulesC:16)
at bip.c(:com.google.android.gms.DynamiteModulesC:99)
at bje.run(:com.google.android.gms.DynamiteModulesC:36)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:762)
这些是我的gradle文件:
classpath 'com.android.tools.build:gradle:2.3.3'
classpath 'com.google.gms:google-services:3.1.0'
classpath 'com.google.firebase:firebase-plugins:1.1.1'
火力地堡
compile "com.google.firebase:firebase-core:11.0.4"
compile "com.google.firebase:firebase-database:11.0.4"
compile "com.google.firebase:firebase-storage:11.0.4"
compile "com.google.firebase:firebase-crash:11.0.4"
compile "com.google.firebase:firebase-auth:11.0.4"
compile "com.google.firebase:firebase-messaging:11.0.4"
compile "com.google.firebase:firebase-config:11.0.4"
compile 'com.firebase:firebase-jobdispatcher:0.7.0'
Google Play服务
compile "com.google.android.gms:play-services-fitness:11.0.4"
compile "com.google.android.gms:play-services-analytics:11.0.4"
compile "com.google.android.gms:play-services-auth:11.0.4"
compile "com.google.android.gms:play-services-location:11.0.4"