Check if mount point is dir during startup

7.0 trees tend to create a /vendor symlink in the root of the
ramdisk. TWRP needs to delete the symlink and mkdir to be able to
mount the partition properly.

Change-Id: Ia338739e07ca16ccd2492ea1fec2f5e99cfc08eb
This commit is contained in:
Ethan Yonker
2016-11-07 22:05:58 -06:00
committed by Dees Troy
parent 79ae093c82
commit 93ac7a0bb1
+2
View File
@@ -778,6 +778,8 @@ bool TWPartition::Is_Image(string File_System) {
}
bool TWPartition::Make_Dir(string Path, bool Display_Error) {
if (TWFunc::Get_D_Type_From_Stat(Path) != S_IFDIR)
unlink(Path.c_str());
if (!TWFunc::Path_Exists(Path)) {
if (mkdir(Path.c_str(), 0777) == -1) {
if (Display_Error)