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

Issue 7573001: Fix subtle memory issues detected by valgrind. (Closed)

Created:
9 years, 4 months ago by satorux1
Modified:
9 years, 4 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Fix subtle memory issues detected by valgrind. The size of dbus_bool_t and the size of bool are different. The former is always 4, whereas the latter is usually 1. The misuse of these types causes subtle memory issues where some D-Bus functions read 4 bytes from a bool pointer, or write 4 bytes to it. These functions take void* so type checking didn't help. TEST=tools/valgrind/valgrind.sh ninja/dbus_unittests BUG=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=95512

Patch Set 1 #

Total comments: 4

Patch Set 2 : address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -4 lines) Patch
M dbus/message.cc View 1 4 chunks +22 lines, -4 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
satorux1
9 years, 4 months ago (2011-08-03 20:09:07 UTC) #1
stevenjb
http://codereview.chromium.org/7573001/diff/1/dbus/message.cc File dbus/message.cc (right): http://codereview.chromium.org/7573001/diff/1/dbus/message.cc#newcode489 dbus/message.cc:489: *value = dbus_value; on some compilers this may require ...
9 years, 4 months ago (2011-08-03 20:39:59 UTC) #2
satorux1
http://codereview.chromium.org/7573001/diff/1/dbus/message.cc File dbus/message.cc (right): http://codereview.chromium.org/7573001/diff/1/dbus/message.cc#newcode489 dbus/message.cc:489: *value = dbus_value; On 2011/08/03 20:40:00, Steven Bennetts wrote: ...
9 years, 4 months ago (2011-08-03 20:43:04 UTC) #3
stevenjb
lgtm
9 years, 4 months ago (2011-08-03 20:46:05 UTC) #4
commit-bot: I haz the power
9 years, 4 months ago (2011-08-04 21:57:22 UTC) #5
Change committed as 95512

Powered by Google App Engine
This is Rietveld 408576698