OSDN Git Service

Reimplement ZipFileRO in terms of libziparchive.
authorNarayan Kamath <narayan@google.com>
Tue, 3 Dec 2013 13:16:03 +0000 (13:16 +0000)
committerNarayan Kamath <narayan@google.com>
Mon, 9 Dec 2013 16:23:16 +0000 (16:23 +0000)
commitafd31e08299008fdc5c2813f21b2573f29dc53df
tree7f83dd8f1e7ed71d4fe8ce280841e43ce275ac6d
parent6e2d0c1d91f644ab50e0c0b7cae4306262a4ca41
Reimplement ZipFileRO in terms of libziparchive.

This lets us share zip archive processing code with both
the runtime (Art, dalvik) and critical java code
(StrictJarFile).

This change also moves several utility methods to ZipUtils
and dedups code across several zip inflation methods.

One of the side effects of this change is that several
processing loops are now O(n) instead of O(n^2).

bug: 10193060

Change-Id: I3c7188496837a47246c4f342e45485a70fef3169
13 files changed:
cmds/bootanimation/BootAnimation.cpp
cmds/bootanimation/BootAnimation.h
core/jni/com_android_internal_content_NativeLibraryHelper.cpp
include/androidfw/ZipFileRO.h
include/androidfw/ZipUtils.h
libs/androidfw/Android.mk
libs/androidfw/Asset.cpp
libs/androidfw/AssetManager.cpp
libs/androidfw/ZipFileRO.cpp
libs/androidfw/ZipUtils.cpp
libs/androidfw/tests/Android.mk
libs/androidfw/tests/ZipUtils_test.cpp [moved from libs/androidfw/tests/ZipFileRO_test.cpp with 87% similarity]
tools/aapt/Android.mk