• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签

Frequently used words (click to add to your profile)

javaandroidc++linuxc#objective-ccocoa誰得qtrubypythongamewindowsbathyscaphephpguic翻訳omegattwitterframeworktestbtronarduinovb.net計画中(planning stage)directxpreviewerゲームエンジンdom

packages/apps/Gallery2


Commit MetaInfo

修订版e9eeb27eb06d675a5290a56d5868f70995b52680 (tree)
时间2018-04-05 18:45:43
作者Jiyong Park <jiyong@goog...>
CommiterJiyong Park

Log Message

Rename android.utils.Pools to com.android.photos.util.Pools

android.utils.Pools is a class copied from frameworks/base. It was
copied because the framework one has been marked as @hide. This caused
the class to be duplicated into the Gallery2 apk and the boot classpath.
At run-time, the class from bootclasspath was used because the
classloader tries to load a class from the parent class loader first.

However, this combined with the recent activation of the kill-switch
caused a runtime error. Working around the issue by renaming the class
copied into the app so that it does not collide with the
framework-defined one.

Bug: 77544391
Test: build aosp_walleye. Take a video and see it via the Gallery2.
The app does not crash.

Change-Id: Ia0af4da84242044da2e0ab63e38df243d9769418

更改概述

差异

--- a/Android.mk
+++ b/Android.mk
@@ -39,6 +39,8 @@ LOCAL_PROGUARD_FLAG_FILES := proguard.flags
3939
4040 LOCAL_JAVA_LIBRARIES += org.apache.http.legacy
4141
42+LOCAL_JARJAR_RULES := $(LOCAL_PATH)/jarjar-rules.txt
43+
4244 include $(BUILD_PACKAGE)
4345
4446 ifeq ($(strip $(LOCAL_PACKAGE_OVERRIDES)),)
--- /dev/null
+++ b/jarjar-rules.txt
@@ -0,0 +1 @@
1+rule android.util.Pools** com.android.photos.util.Pools@1
--- a/proguard.flags
+++ b/proguard.flags
@@ -84,5 +84,3 @@
8484 -keep class com.android.gallery3d.jpegstream.StreamUtils { *; }
8585
8686
87-# TODO: remove or rename android.util.Pools.java from our source.
88--dontwarn android.util.Pools*