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

Issue 7888011: There is a complain from Valgrind about invalid memory access in snd_device_name_hint(-1, ..) // ... (Closed)

Created:
9 years, 3 months ago by no longer working on chromium
Modified:
9 years, 3 months ago
CC:
chromium-reviews, hclam+watch_chromium.org, ddorwin+watch_chromium.org, fischman+watch_chromium.org, acolwell+watch_chromium.org, annacc+watch_chromium.org, ajwong+watch_chromium.org, vrk (LEFT CHROMIUM), scherkus (not reviewing)
Visibility:
Public.

Description

There is a complain from Valgrind about invalid memory access in snd_device_name_hint(-1, ..) // -1 means all cards. It looks like the problem is actually because we use -1 to loop through all the soundcards. And this patch will loop through the soundcard manually, which should resolve the Valgrind problem. Bug=96207 Test=media_unittests with Valgrind Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=101240

Patch Set 1 #

Total comments: 4

Patch Set 2 : '' #

Total comments: 2

Patch Set 3 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -34 lines) Patch
M media/audio/linux/alsa_wrapper.h View 1 chunk +1 line, -0 lines 0 comments Download
M media/audio/linux/alsa_wrapper.cc View 1 chunk +4 lines, -0 lines 0 comments Download
M media/audio/linux/audio_manager_linux.cc View 1 1 chunk +17 lines, -13 lines 0 comments Download
M tools/valgrind/memcheck/suppressions.txt View 1 2 1 chunk +0 lines, -21 lines 0 comments Download

Messages

Total messages: 13 (0 generated)
Alexander Potapenko
http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc File media/audio/linux/audio_manager_linux.cc (right): http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc#newcode72 media/audio/linux/audio_manager_linux.cc:72: // Don't use snd_device_name_hint(-1,..) since there is a memory ...
9 years, 3 months ago (2011-09-13 17:03:03 UTC) #1
Raymond Toy (Google)
http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc File media/audio/linux/audio_manager_linux.cc (left): http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc#oldcode84 media/audio/linux/audio_manager_linux.cc:84: wrapper_->DeviceNameFreeHint(hints); Won't there be a real leak now since ...
9 years, 3 months ago (2011-09-13 17:07:40 UTC) #2
wjia(left Chromium)
Nice work! I also tried your patch with suppression removed and it succeeds valgrind bot. ...
9 years, 3 months ago (2011-09-14 03:37:17 UTC) #3
xians
Fix the comment; Wait for a owner stamp to commit. http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc File media/audio/linux/audio_manager_linux.cc (left): http://codereview.chromium.org/7888011/diff/1/media/audio/linux/audio_manager_linux.cc#oldcode84 ...
9 years, 3 months ago (2011-09-14 08:12:00 UTC) #4
_com_google_glider
Your patch indeed fixes the errors reported by AddressSanitizer in media_unittests and content_unittests. Thanks for ...
9 years, 3 months ago (2011-09-14 09:18:37 UTC) #5
scherkus (not reviewing)
http://codereview.chromium.org/7888011/diff/5/media/audio/linux/audio_manager_linux.cc File media/audio/linux/audio_manager_linux.cc (right): http://codereview.chromium.org/7888011/diff/5/media/audio/linux/audio_manager_linux.cc#newcode85 media/audio/linux/audio_manager_linux.cc:85: LOG(ERROR) << "Unable to get device hints: " << ...
9 years, 3 months ago (2011-09-14 16:32:31 UTC) #6
scherkus (not reviewing)
also do you plan on removing the suppression?
9 years, 3 months ago (2011-09-14 16:33:07 UTC) #7
xians
Andrew, could you please guide me how to remove the suppression? http://codereview.chromium.org/7888011/diff/5/media/audio/linux/audio_manager_linux.cc File media/audio/linux/audio_manager_linux.cc (right): ...
9 years, 3 months ago (2011-09-14 16:36:54 UTC) #8
wjia(left Chromium)
It seems that build bots and try bots don't have sound card. When snd_device_name_hint is ...
9 years, 3 months ago (2011-09-14 18:11:23 UTC) #9
scherkus (not reviewing)
I'm confused -- are you going to update the source code to check for devices ...
9 years, 3 months ago (2011-09-14 18:45:50 UTC) #10
wjia(left Chromium)
On Wed, Sep 14, 2011 at 11:45 AM, <scherkus@chromium.org> wrote: > I'm confused -- are ...
9 years, 3 months ago (2011-09-14 18:56:44 UTC) #11
commit-bot: I haz the power
Try job failure for 7888011-3002 (retry) on win for step "compile" (clobber build). It's a ...
9 years, 3 months ago (2011-09-14 20:30:29 UTC) #12
commit-bot: I haz the power
9 years, 3 months ago (2011-09-15 03:59:37 UTC) #13
Change committed as 101240

Powered by Google App Engine
This is Rietveld 408576698