diff --git a/Utils.cpp b/Utils.cpp
index 667d277..341c927 100644
--- a/Utils.cpp
+++ b/Utils.cpp
@@ -811,7 +811,7 @@
         return -errno;
     }
 
-    status_t result;
+    status_t result = OK;
     struct dirent* de;
     while ((de = readdir(dir))) {
         const char* name = de->d_name;
diff --git a/VolumeManager.cpp b/VolumeManager.cpp
index 32747d4..547c7ef 100644
--- a/VolumeManager.cpp
+++ b/VolumeManager.cpp
@@ -871,8 +871,8 @@
     if (hasIsolatedStorage()) {
         mUserPackages.erase(userId);
         std::string mntTargetDir = StringPrintf("/mnt/user/%d", userId);
-        if (android::vold::UnmountTree(mntTargetDir) != 0) {
-            PLOG(ERROR) << "unmountTree on " << mntTargetDir << " failed";
+        if (android::vold::UnmountTreeWithPrefix(mntTargetDir) < 0) {
+            PLOG(ERROR) << "UnmountTreeWithPrefix on " << mntTargetDir << " failed";
             return -errno;
         }
         if (android::vold::DeleteDirContentsAndDir(mntTargetDir) < 0) {
@@ -974,8 +974,8 @@
                  << ", volLabel=" << volLabel;
     std::string pkgSandboxTarget =
         StringPrintf("/mnt/user/%d/package/%s", userId, packageName.c_str());
-    if (android::vold::UnmountTree(pkgSandboxTarget)) {
-        PLOG(ERROR) << "UnmountTree failed on " << pkgSandboxTarget;
+    if (android::vold::UnmountTreeWithPrefix(pkgSandboxTarget) < 0) {
+        PLOG(ERROR) << "UnmountTreeWithPrefix failed on " << pkgSandboxTarget;
     }
 
     std::string sandboxDir = StringPrintf("/mnt/runtime/write/%s", volLabel.c_str());
@@ -1075,8 +1075,8 @@
     for (auto& packageName : packageNames) {
         std::string volSandboxRoot = StringPrintf("/mnt/user/%d/package/%s/%s", userId,
                                                   packageName.c_str(), vol->getLabel().c_str());
-        if (android::vold::UnmountTree(volSandboxRoot) != 0) {
-            PLOG(ERROR) << "unmountTree on " << volSandboxRoot << " failed";
+        if (android::vold::UnmountTreeWithPrefix(volSandboxRoot) < 0) {
+            PLOG(ERROR) << "UnmountTreeWithPrefix on " << volSandboxRoot << " failed";
             continue;
         }
         if (android::vold::DeleteDirContentsAndDir(volSandboxRoot) < 0) {
@@ -1288,7 +1288,7 @@
     mVisibleVolumeIds.clear();
 
     // For unmounting dirs under /mnt/user/<user-id>/package/<package-name>
-    android::vold::UnmountTree("/mnt/user/");
+    android::vold::UnmountTreeWithPrefix("/mnt/user/");
     return 0;
 }
 
