diff options
Diffstat (limited to 'chrome/browser/chromeos/cros/mount_library.cc')
-rw-r--r-- | chrome/browser/chromeos/cros/mount_library.cc | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/chrome/browser/chromeos/cros/mount_library.cc b/chrome/browser/chromeos/cros/mount_library.cc index 6fcbdb0..952f1dd 100644 --- a/chrome/browser/chromeos/cros/mount_library.cc +++ b/chrome/browser/chromeos/cros/mount_library.cc @@ -728,10 +728,16 @@ class MountLibraryImpl : public MountLibrary { } const char* FilePathToDevicePath(const char* file_path) { + int failed = (file_path[0] == '!') ? 1 : 0; for (MountLibrary::DiskMap::iterator it = disks_.begin(); it != disks_.end(); ++it) { - if (it->second->file_path().compare(file_path) == 0) - return it->second->device_path().c_str(); + if (it->second->file_path().compare(file_path + failed) == 0) { + if (failed) { + return (std::string("!") + it->second->device_path()).c_str(); + } else { + return it->second->device_path().c_str(); + } + } } return NULL; } |