Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(304)

Issue 6562001: chromeos: Check ALSA return values in mixer code. (Closed)

Created:
9 years, 10 months ago by Daniel Erat
Modified:
9 years, 7 months ago
Reviewers:
davejcool
CC:
chromium-reviews, davemoore+watch_chromium.org, zel
Visibility:
Public.

Description

chromeos: Check ALSA return values in mixer code. We're seeing a NaN value sometimes get saved (incorrectly) to the prefs file in the volume setting, which results in the prefs file being unparseable the next time Chrome starts, which results in us going through OOBE again. The prefs code ought to write NaNs correctly so that they don't corrupt the file, but in the meantime, this change checks the return values from a bunch of ALSA functions (my best theory as to how the NaN is creeping in) and for good measure, also maps NaN volume values to the minimum volume. BUG=chromium-os:12229 TEST=built and ran it (i haven't been able to repro the problem) Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=75698

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+79 lines, -25 lines) Patch
M chrome/browser/chromeos/audio_mixer_alsa.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/chromeos/audio_mixer_alsa.cc View 11 chunks +78 lines, -25 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Daniel Erat
9 years, 10 months ago (2011-02-23 02:25:41 UTC) #1
davejcool
9 years, 10 months ago (2011-02-23 02:35:50 UTC) #2
LGTM.

If nothing else, the extensive checking of alsa return values should shed light
on what is causing the -Nan value.

Powered by Google App Engine
This is Rietveld 408576698