History log of /dalvik/libdex/ZipArchive.h
Revision Date Author Comments
39e8b7e287742ea1e1af58d6b25e12897cf66632 17-Dec-2013 Narayan Kamath <narayan@google.com> Revert "Revert "Use libziparchive for dalvik zip processing.""

This reverts commit 52dacd58ac8735ffdcd6bbe952586a38ad70e6a5.
52dacd58ac8735ffdcd6bbe952586a38ad70e6a5 16-Dec-2013 Guang Zhu <guangzhu@google.com> Revert "Use libziparchive for dalvik zip processing."

Bug: 12173498

This reverts commit ac4202a846965a6b5a88001a8ad3d5321edeb81c.

Change-Id: Ie48d873bded13e0f73cb1e926dbcd30a66933176
ac4202a846965a6b5a88001a8ad3d5321edeb81c 13-Dec-2013 Narayan Kamath <narayan@google.com> Use libziparchive for dalvik zip processing.

The API was similar enough that we could just delegate
to existing zip functions. The existing ZipArchiveHandle /
ZipEntry types have been reused instead of defining new
types.

The old ZipArchive type has been removed because it serves
no useful purpose, and no code was using it anyway.

Change-Id: I47f12344d1e6efc234fed50b1613f9f179a9b03f
375fb116bcb817b37509ab579dbd55cdbb765cbf 15-Jun-2011 Carl Shapiro <cshapiro@google.com> Normalize the include guard style.

An leading underscore followed by a capital letter is a reserved
name space in C and C++.

This change also moves any #include directives within the include
guard in some of the compiler/codegen/arm header files.

Change-Id: I9715e2c5301699d31886e61d0fe6e29483555a2a
bfc9799b1a53fd6f6136d07e6278d4538cf70f13 27-Apr-2011 Carl Shapiro <cshapiro@google.com> Make libdex structures tool friendly.

Previously, the struct name and its typedef name were identical. This
confuses emacs and etags. This change eliminates the typedef names and
removes the extern "C" wrapping the libdex header files. To support
this change the transitive C dependencies have been made to compile as
C++ instead.

Change-Id: I7065f32d61d776f9b09c7b461adf2502268d852f
db0c9549818d9f6e508d26e45ff9d886802aa1da 13-Apr-2011 Carl Shapiro <cshapiro@google.com> Convert the internal and in-line natives to C++.

Change-Id: I2ece682bc3b4d3b55ab27c60fd84a0b3243d7ca6
80a4e2497c3b5ef24fe1408c678053fbc6cd4b25 24-Apr-2010 Andy McFadden <fadden@android.com> Dalvik Zip rewrite.

Change the way zip archives are handled. This is necessary to deal with
very large (~1GB) APK files, for which our current approach of mapping
the entire file falls over.

We now do the classic scavenger hunt for the End Of Central Directory magic
on a buffer of data read from the file, instead of a memory-mapped section.
We use what we find to create a map that covers the Central Directory only.
For most uses in the VM this is all we really need, since we just want
to check file attributes vs. the optimized DEX to see if we're out of date.

If the caller is interested in unpacking the file contents, we have to
do an additional file read to discover the size of the Local File Header
section so we can skip past it. We also now do a file-to-file extraction
using read() calls instead of a buffer-to-file extraction on mmap()ed data.
No difference in performance (as measured by first-boot dexopt).

Since this is more of a rewrite than an update, I also took the opportunity
to change buffer size variables from "long" to "size_t", and normalized
return values to int (some were using bool, which is common in the VM but
was mixed in the zip code). Failure messages are now all LOGW with the
word "Zip" up front (didn't want to change log tag away from "dalvikvm").

Also, removed a not-quite-right check in the "map part of a file" code,
and clarified that the file offset is absolute.

For bug 2620103.

Change-Id: I745fb15abb541376f467969ffe422222676f1e5f
8911f7a2222124ba724a4a9281555b74d0e098e2 24-Apr-2010 Andy McFadden <fadden@android.com> Dalvik Zip rewrite.

Change the way zip archives are handled. This is necessary to deal with
very large (~1GB) APK files, for which our current approach of mapping
the entire file falls over.

We now do the classic scavenger hunt for the End Of Central Directory magic
on a buffer of data read from the file, instead of a memory-mapped section.
We use what we find to create a map that covers the Central Directory only.
For most uses in the VM this is all we really need, since we just want
to check file attributes vs. the optimized DEX to see if we're out of date.

If the caller is interested in unpacking the file contents, we have to
do an additional file read to discover the size of the Local File Header
section so we can skip past it. We also now do a file-to-file extraction
using read() calls instead of a buffer-to-file extraction on mmap()ed data.
No difference in performance (as measured by first-boot dexopt).

Since this is more of a rewrite than an update, I also took the opportunity
to change buffer size variables from "long" to "size_t", and normalized
return values to int (some were using bool, which is common in the VM but
was mixed in the zip code). Failure messages are now all LOGW with the
word "Zip" up front (didn't want to change log tag away from "dalvikvm").

Also, removed a not-quite-right check in the "map part of a file" code,
and clarified that the file offset is absolute.

For bug 2620103.

Change-Id: I745fb15abb541376f467969ffe422222676f1e5f
f6c387128427e121477c1b32ad35cdcaa5101ba3 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
f72d5de56a522ac3be03873bdde26f23a5eeeb3c 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
2ad60cfc28e14ee8f0bb038720836a4696c478ad 21-Oct-2008 The Android Open Source Project <initial-contribution@android.com> Initial Contribution