*pCachedName = buf;
return fd;
}
- LOGV("Couldn't open %s: %s", buf, strerror(errno));
+ ALOGV("Couldn't open %s: %s", buf, strerror(errno));
bail:
free(buf);
return -1;
* See if there's an up-to-date copy of the optimized dex
* in the cache, but don't create one if there isn't.
*/
- LOGV("dvmDexCacheStatus: Checking cache for %s", fileName);
+ ALOGV("dvmDexCacheStatus: Checking cache for %s", fileName);
cachedName = dexOptGenerateCacheFileName(fileName, kDexInJarName);
if (cachedName == NULL)
return DEX_CACHE_BAD_ARCHIVE;
dexGetZipEntryModTime(&archive, entry),
dexGetZipEntryCrc32(&archive, entry),
/*isBootstrap=*/false, &newFile, /*createIfMissing=*/false);
- LOGV("dvmOpenCachedDexFile returned fd %d", fd);
+ ALOGV("dvmOpenCachedDexFile returned fd %d", fd);
if (fd < 0) {
result = DEX_CACHE_STALE;
goto bail;
*/
if (!dvmUnlockCachedDexFile(fd)) {
/* uh oh -- this process needs to exit or we'll wedge the system */
- LOGE("Unable to unlock DEX file");
+ ALOGE("Unable to unlock DEX file");
goto bail;
}
*/
fd = openAlternateSuffix(fileName, "odex", O_RDONLY, &cachedName);
if (fd < 0) {
- LOGI("Zip is good, but no %s inside, and no .odex "
- "file in the same directory\n", kDexInJarName);
+ ALOGI("Zip is good, but no %s inside, and no .odex "
+ "file in the same directory", kDexInJarName);
result = DEX_CACHE_BAD_ARCHIVE;
goto bail;
}
- LOGV("Using alternate file (odex) for %s ...", fileName);
+ ALOGV("Using alternate file (odex) for %s ...", fileName);
if (!dvmCheckOptHeaderAndDependencies(fd, false, 0, 0, true, true)) {
- LOGE("%s odex has stale dependencies", fileName);
- LOGE("odex source not available -- failing");
+ ALOGE("%s odex has stale dependencies", fileName);
+ ALOGE("odex source not available -- failing");
result = DEX_CACHE_STALE_ODEX;
goto bail;
} else {
- LOGV("%s odex has good dependencies", fileName);
+ ALOGV("%s odex has good dependencies", fileName);
}
}
result = DEX_CACHE_OK;
*/
fd = openAlternateSuffix(fileName, "odex", O_RDONLY, &cachedName);
if (fd >= 0) {
- LOGV("Using alternate file (odex) for %s ...", fileName);
+ ALOGV("Using alternate file (odex) for %s ...", fileName);
if (!dvmCheckOptHeaderAndDependencies(fd, false, 0, 0, true, true)) {
- LOGE("%s odex has stale dependencies", fileName);
+ ALOGE("%s odex has stale dependencies", fileName);
free(cachedName);
cachedName = NULL;
close(fd);
fd = -1;
goto tryArchive;
} else {
- LOGV("%s odex has good dependencies", fileName);
+ ALOGV("%s odex has good dependencies", fileName);
//TODO: make sure that the .odex actually corresponds
// to the classes.dex inside the archive (if present).
// For typical use there will be no classes.dex.
} else {
cachedName = strdup(odexOutputName);
}
- LOGV("dvmJarFileOpen: Checking cache for %s (%s)",
+ ALOGV("dvmJarFileOpen: Checking cache for %s (%s)",
fileName, cachedName);
fd = dvmOpenCachedDexFile(fileName, cachedName,
dexGetZipEntryModTime(&archive, entry),
dexGetZipEntryCrc32(&archive, entry),
isBootstrap, &newFile, /*createIfMissing=*/true);
if (fd < 0) {
- LOGI("Unable to open or create cache for %s (%s)",
+ ALOGI("Unable to open or create cache for %s (%s)",
fileName, cachedName);
goto bail;
}
}
if (!result) {
- LOGE("Unable to extract+optimize DEX from '%s'",
+ ALOGE("Unable to extract+optimize DEX from '%s'",
fileName);
goto bail;
}
endWhen = dvmGetRelativeTimeUsec();
- LOGD("DEX prep '%s': unzip in %dms, rewrite %dms",
+ ALOGD("DEX prep '%s': unzip in %dms, rewrite %dms",
fileName,
(int) (extractWhen - startWhen) / 1000,
(int) (endWhen - extractWhen) / 1000);
}
} else {
- LOGI("Zip is good, but no %s inside, and no valid .odex "
- "file in the same directory\n", kDexInJarName);
+ ALOGI("Zip is good, but no %s inside, and no valid .odex "
+ "file in the same directory", kDexInJarName);
goto bail;
}
}
* doesn't have to be seeked anywhere in particular.
*/
if (dvmDexFileOpenFromFd(fd, &pDvmDex) != 0) {
- LOGI("Unable to map %s in %s", kDexInJarName, fileName);
+ ALOGI("Unable to map %s in %s", kDexInJarName, fileName);
goto bail;
}
/* unlock the fd */
if (!dvmUnlockCachedDexFile(fd)) {
/* uh oh -- this process needs to exit or we'll wedge the system */
- LOGE("Unable to unlock DEX file");
+ ALOGE("Unable to unlock DEX file");
goto bail;
}
locked = false;
}
- LOGV("Successfully opened '%s' in '%s'", kDexInJarName, fileName);
+ ALOGV("Successfully opened '%s' in '%s'", kDexInJarName, fileName);
*ppJarFile = (JarFile*) calloc(1, sizeof(JarFile));
(*ppJarFile)->archive = archive;