Fix the incorrect parameter quota when userdata is formatted with EXT4
The userdata will be formatted by VOLD during bootup when the userdata
is not completed file system(EXT4 or F2FS).
For EXT4 on userdata and quota feature is enabled. the parameter quota
is incorrect in ext4::Format(). Change the parameter from
quotatype=prjquota to quotatype=usrquota:grpquota:prjquota.
Bug: 199802158
Test: run cts-on-gsi -m CtsAppSecurityHostTestCases -t
android.appsecurity.cts.StorageHostTest
Change-Id: Ibff10e8e67b4e6ffabea97f534ff6551aed91963
diff --git a/fs/Ext4.cpp b/fs/Ext4.cpp
index 6bc7ad2..7a5f5da 100644
--- a/fs/Ext4.cpp
+++ b/fs/Ext4.cpp
@@ -198,7 +198,7 @@
cmd.push_back("-E");
std::string extopts = "";
if (needs_casefold) extopts += "encoding=utf8,";
- if (needs_projid) extopts += "quotatype=prjquota,";
+ if (needs_projid) extopts += "quotatype=usrquota:grpquota:prjquota,";
cmd.push_back(extopts);
}