summaryrefslogtreecommitdiffstats
path: root/partition.cpp
diff options
context:
space:
mode:
authorEthan Yonker <dees_troy@teamw.in>2014-12-11 17:00:45 +0100
committerEthan Yonker <dees_troy@teamw.in>2014-12-12 16:20:42 +0100
commit4b94cfd3910de26dbca64cf746a899cbc635158b (patch)
tree9b452fb2632413e51cb3b9fd8b28e6a2bd0352f5 /partition.cpp
parentFix loading of png images in custom themes (diff)
downloadandroid_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar.gz
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar.bz2
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar.lz
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar.xz
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.tar.zst
android_bootable_recovery-4b94cfd3910de26dbca64cf746a899cbc635158b.zip
Diffstat (limited to '')
-rw-r--r--partition.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/partition.cpp b/partition.cpp
index d84e48fae..b3c436f8b 100644
--- a/partition.cpp
+++ b/partition.cpp
@@ -42,6 +42,7 @@
#include "twrpDU.hpp"
#include "fixPermissions.hpp"
#include "infomanager.hpp"
+#include "set_metadata.h"
extern "C" {
#include "mtdutils/mtdutils.h"
#include "mtdutils/mounts.h"
@@ -1748,6 +1749,7 @@ bool TWPartition::Backup_DD(string backup_folder) {
Command = "dd if=" + Actual_Block_Device + " of='" + Full_FileName + "'" + " bs=" + DD_BS + " count=1";
LOGINFO("Backup command: '%s'\n", Command.c_str());
TWFunc::Exec_Cmd(Command);
+ tw_set_default_metadata(Full_FileName.c_str());
if (TWFunc::Get_File_Size(Full_FileName) == 0) {
LOGERR("Backup file size for '%s' is 0 bytes.\n", Full_FileName.c_str());
return false;
@@ -1771,6 +1773,7 @@ bool TWPartition::Backup_Dump_Image(string backup_folder) {
Command = "dump_image " + MTD_Name + " '" + Full_FileName + "'";
LOGINFO("Backup command: '%s'\n", Command.c_str());
TWFunc::Exec_Cmd(Command);
+ tw_set_default_metadata(Full_FileName.c_str());
if (TWFunc::Get_File_Size(Full_FileName) == 0) {
// Actual size may not match backup size due to bad blocks on MTD devices so just check for 0 bytes
LOGERR("Backup file size for '%s' is 0 bytes.\n", Full_FileName.c_str());