summaryrefslogtreecommitdiffstats
path: root/partitionmanager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'partitionmanager.cpp')
-rw-r--r--partitionmanager.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/partitionmanager.cpp b/partitionmanager.cpp
index c99447ff0..98151b43c 100644
--- a/partitionmanager.cpp
+++ b/partitionmanager.cpp
@@ -1283,6 +1283,26 @@ int TWPartitionManager::Wipe_Battery_Stats(void) {
return true;
}
+int TWPartitionManager::Wipe_Android_Secure(void) {
+ std::vector<TWPartition*>::iterator iter;
+ int ret = false;
+ bool found = false;
+
+ // Iterate through all partitions
+ for (iter = Partitions.begin(); iter != Partitions.end(); iter++) {
+ if ((*iter)->Has_Android_Secure) {
+ ret = (*iter)->Wipe_AndSec();
+ found = true;
+ }
+ }
+ if (found) {
+ return ret;
+ } else {
+ LOGE("No android secure partitions found.\n");
+ }
+ return false;
+}
+
int TWPartitionManager::Format_Data(void) {
TWPartition* dat = Find_Partition_By_Path("/data");