need to specify a backup directory if none is given
This commit is contained in:
parent
b9546a8047
commit
7e0a72c8b3
@ -26,7 +26,7 @@ LOCAL_MODULE := recovery
|
||||
|
||||
LOCAL_FORCE_STATIC_EXECUTABLE := true
|
||||
|
||||
RECOVERY_API_VERSION := 1.7.0
|
||||
RECOVERY_API_VERSION := 1.7.1
|
||||
LOCAL_CFLAGS += -DRECOVERY_API_VERSION=$(RECOVERY_API_VERSION)
|
||||
|
||||
# This binary is in the recovery ramdisk, which is otherwise a copy of root.
|
||||
|
@ -767,9 +767,16 @@ cmd_backup_rom(const char *name, void *cookie, int argc, const char *argv[],
|
||||
CHECK_WORDS();
|
||||
|
||||
char* backup_name = NULL;
|
||||
char backup_path[PATH_MAX];
|
||||
switch(argc)
|
||||
{
|
||||
case 0:
|
||||
{
|
||||
struct timeval tp;
|
||||
gettimeofday(&tp, NULL);
|
||||
sprintf(backup_path, "/sdcard/clockworkmod/backup/%d", tp.tv_sec);
|
||||
backup_name = backup_path;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
backup_name = argv[0];
|
||||
|
Loading…
x
Reference in New Issue
Block a user