summaryrefslogtreecommitdiffstats
path: root/chrome/browser/chromeos
diff options
context:
space:
mode:
authorsatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-09 02:25:01 +0000
committersatorux@chromium.org <satorux@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-09 02:25:01 +0000
commit6c34546631dd18783d82242cbf6e697e693093b0 (patch)
tree99aef32ed88b953b25bbc4c9dee1584f81a27a3f /chrome/browser/chromeos
parent8ffcd00657212cc796b2f711d4794ded158886c8 (diff)
downloadchromium_src-6c34546631dd18783d82242cbf6e697e693093b0.zip
chromium_src-6c34546631dd18783d82242cbf6e697e693093b0.tar.gz
chromium_src-6c34546631dd18783d82242cbf6e697e693093b0.tar.bz2
Fix a potential crash in MountLibraryImpl::Init().
This is not a big deal, as the crash does not occur on the netbook. I encountred a crash when I was trying to run chrome for chrome os with libcros.so on my Ubuntu workstation. Note that building libcros.so outside of chroot is very tricky, so no one else probably wants to do that. TEST=manually BUG=none Review URL: http://codereview.chromium.org/2884015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51915 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/chromeos')
-rw-r--r--chrome/browser/chromeos/cros/mount_library.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/chrome/browser/chromeos/cros/mount_library.cc b/chrome/browser/chromeos/cros/mount_library.cc
index 894bccf8..e99edf2 100644
--- a/chrome/browser/chromeos/cros/mount_library.cc
+++ b/chrome/browser/chromeos/cros/mount_library.cc
@@ -82,6 +82,10 @@ void MountLibraryImpl::MountStatusChangedHandler(void* object,
void MountLibraryImpl::Init() {
// Getting the monitor status so that the daemon starts up.
MountStatus* mount = RetrieveMountInformation();
+ if (!mount) {
+ LOG(ERROR) << "Failed to retrieve mount information";
+ return;
+ }
ParseDisks(*mount);
FreeMountStatus(mount);