summaryrefslogtreecommitdiff
path: root/library/src
diff options
context:
space:
mode:
authorYohann Roussel <yroussel@google.com>2013-11-12 18:11:02 +0100
committerYohann Roussel <yroussel@google.com>2013-11-12 18:11:02 +0100
commitedf0717d4203bd7e9c9435019e3c256d564b4583 (patch)
tree942f142e6648a6161f5a11839b41bbee484ee5bd /library/src
parentaeef2844e435c6cb01741cbb169a593b4afebed0 (diff)
downloadmultidex-edf0717d4203bd7e9c9435019e3c256d564b4583.tar.gz
Keep time extracted entry to avoid multiple dexopt.
Fix bug 11415819 Change-Id: I1a1300f430f0db7b587e2f29c273884ef80f7fbe
Diffstat (limited to 'library/src')
-rw-r--r--library/src/android/support/multidex/MultiDexExtractor.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/library/src/android/support/multidex/MultiDexExtractor.java b/library/src/android/support/multidex/MultiDexExtractor.java
index 220f2aa..bcd9c4d 100644
--- a/library/src/android/support/multidex/MultiDexExtractor.java
+++ b/library/src/android/support/multidex/MultiDexExtractor.java
@@ -140,6 +140,8 @@ final class MultiDexExtractor {
out = new ZipOutputStream(new FileOutputStream(tmp));
try {
ZipEntry classesDex = new ZipEntry("classes.dex");
+ // keep zip entry time since it is the criteria used by Dalvik
+ classesDex.setTime(dexFile.getTime());
out.putNextEntry(classesDex);
byte[] buffer = new byte[BUFFER_SIZE];