From ad774b297010d23911dfc75bb626cf74e374f731 Mon Sep 17 00:00:00 2001 From: Tao Bao Date: Fri, 29 Sep 2017 10:39:08 -0700 Subject: roots: Remove #include "common.h". And add the missing include of (e.g. for strcmp(3)). Minor update to the arg of fs_mgr_get_entry_for_mount_point(), which now accepts std::string. Test: mmma bootable/recovery Change-Id: I9cb8c31fe71b5a053f4d84bf1aba00e96c02ed03 --- roots.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roots.cpp b/roots.cpp index 7d7d1bdc7..02c1ecb7c 100644 --- a/roots.cpp +++ b/roots.cpp @@ -20,6 +20,7 @@ #include #include #include +#include #include #include #include @@ -38,7 +39,6 @@ #include #include -#include "common.h" #include "mounts.h" static struct fstab* fstab = nullptr; @@ -77,7 +77,7 @@ Volume* volume_for_path(const char* path) { if (path == nullptr || path[0] == '\0') return nullptr; std::string str(path); while (true) { - Volume* result = fs_mgr_get_entry_for_mount_point(fstab, str.c_str()); + Volume* result = fs_mgr_get_entry_for_mount_point(fstab, str); if (result != nullptr || str == "/") { return result; } -- cgit v1.2.3