More complete support for fstab in dt

This commit is contained in:
topjohnwu
2020-05-03 22:49:54 -07:00
parent 8ab045331b
commit 0c99c4d93f
7 changed files with 151 additions and 116 deletions

View File

@@ -164,14 +164,6 @@ bool ends_with(const std::string_view &s1, const std::string_view &s2) {
return l1 < l2 ? false : s1.compare(l1 - l2, l2, s2) == 0;
}
char *rtrim(char *str) {
int len = strlen(str);
while (len > 0 && str[len - 1] == ' ')
--len;
str[len] = '\0';
return str;
}
/*
* Bionic's atoi runs through strtol().
* Use our own implementation for faster conversion.