summaryrefslogtreecommitdiffstats
path: root/roots.cpp
diff options
context:
space:
mode:
authorTao Bao <tbao@google.com>2017-10-02 19:55:13 +0200
committerandroid-build-merger <android-build-merger@google.com>2017-10-02 19:55:13 +0200
commit0fa08924c6c3c434c18f9c396d066aeb1adfc1cb (patch)
treee6f96585d05ec9196dce0a0cf46b42427c78b2c1 /roots.cpp
parentMerge "otafault: Move to soong." (diff)
parentMerge "roots: Remove #include "common.h"." (diff)
downloadandroid_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar.gz
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar.bz2
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar.lz
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar.xz
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.tar.zst
android_bootable_recovery-0fa08924c6c3c434c18f9c396d066aeb1adfc1cb.zip
Diffstat (limited to '')
-rw-r--r--roots.cpp4
1 files 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 <fcntl.h>
#include <stdint.h>
#include <stdlib.h>
+#include <string.h>
#include <sys/mount.h>
#include <sys/stat.h>
#include <sys/types.h>
@@ -38,7 +39,6 @@
#include <ext4_utils/wipe.h>
#include <fs_mgr.h>
-#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;
}