bug fixes
Change-Id: I1125db9cb1a12a95060f7673965fd40994a78c5b
This commit is contained in:
parent
fcb87af735
commit
7905c80940
@ -26,7 +26,7 @@ LOCAL_MODULE := recovery
|
||||
|
||||
LOCAL_FORCE_STATIC_EXECUTABLE := true
|
||||
|
||||
RECOVERY_VERSION := ClockworkMod Recovery v4.0.0.3
|
||||
RECOVERY_VERSION := ClockworkMod Recovery v4.0.0.4
|
||||
LOCAL_CFLAGS += -DRECOVERY_VERSION="$(RECOVERY_VERSION)"
|
||||
RECOVERY_API_VERSION := 2
|
||||
LOCAL_CFLAGS += -DRECOVERY_API_VERSION=$(RECOVERY_API_VERSION)
|
||||
|
10
nandroid.c
10
nandroid.c
@ -315,13 +315,13 @@ static void ensure_directory(const char* dir) {
|
||||
__system(tmp);
|
||||
}
|
||||
|
||||
typedef int (*nandroid_restore_handler)(const char* backup_file_image, const char* backup_path, file_event_callback callback);
|
||||
typedef int (*nandroid_restore_handler)(const char* backup_file_image, const char* backup_path, int callback);
|
||||
|
||||
static int unyaffs_wrapper(const char* backup_file_image, const char* backup_path, file_event_callback callback) {
|
||||
static int unyaffs_wrapper(const char* backup_file_image, const char* backup_path, int callback) {
|
||||
return unyaffs(backup_file_image, backup_path, callback);
|
||||
}
|
||||
|
||||
static int tar_extract_wrapper(const char* backup_file_image, const char* backup_path, file_event_callback callback) {
|
||||
static int tar_extract_wrapper(const char* backup_file_image, const char* backup_path, int callback) {
|
||||
char tmp[PATH_MAX];
|
||||
sprintf(tmp, "cd $(dirname %s) ; tar xvf %s ; exit $?", backup_path, backup_file_image);
|
||||
|
||||
@ -333,8 +333,8 @@ static int tar_extract_wrapper(const char* backup_file_image, const char* backup
|
||||
}
|
||||
|
||||
while (fgets(path, PATH_MAX, fp) != NULL) {
|
||||
if (NULL != callback)
|
||||
callback(path);
|
||||
if (callback)
|
||||
yaffs_callback(path);
|
||||
}
|
||||
|
||||
return __pclose(fp);
|
||||
|
4
roots.c
4
roots.c
@ -287,8 +287,8 @@ int format_volume(const char* volume) {
|
||||
Volume* v = volume_for_path(volume);
|
||||
if (v == NULL) {
|
||||
// no /sdcard? let's assume /data/media
|
||||
if (strstr(path, "/sdcard") == path && is_data_media()) {
|
||||
return format_unknown_device(v->device, volume, NULL);
|
||||
if (strstr(volume, "/sdcard") == volume && is_data_media()) {
|
||||
return format_unknown_device(NULL, volume, NULL);
|
||||
}
|
||||
// silent failure for sd-ext
|
||||
if (strcmp(volume, "/sd-ext") == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user