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

Issue 4228002: Moved ownership of camera thread to user image screen (Closed)

Created:
10 years, 1 month ago by whywhat
Modified:
9 years, 7 months ago
Reviewers:
DaveMoore, sky
CC:
chromium-reviews, nkostylev+cc_chromium.org, davemoore+watch_chromium.org, ben+cc_chromium.org
Visibility:
Public.

Description

Moved ownership of camera thread to user image screen. Patch of http://codereview.chromium.org/4106015/show BUG=chromium-os:8440 TEST=Ensure that there is no crash after taking picture. Try several times, as this is timing related. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=64800

Patch Set 1 #

Patch Set 2 : Moved ownership of camera thread to user image screen #

Total comments: 2

Patch Set 3 : Made locks local instead of static #

Patch Set 4 : Compile fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+44 lines, -66 lines) Patch
M chrome/browser/chromeos/login/camera.h View 1 2 3 6 chunks +12 lines, -18 lines 0 comments Download
M chrome/browser/chromeos/login/camera.cc View 1 2 13 chunks +21 lines, -46 lines 0 comments Download
M chrome/browser/chromeos/login/user_image_screen.h View 1 2 chunks +4 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/login/user_image_screen.cc View 1 1 chunk +7 lines, -2 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
whywhat
PTAL
10 years, 1 month ago (2010-11-02 15:03:05 UTC) #1
whywhat
Actually this doesn't eliminate the race since OnUninitializeSuccess can still be executed on UI thread ...
10 years, 1 month ago (2010-11-02 16:07:30 UTC) #2
whywhat
I uploaded a new fix with camera thread separated from camera object. The thread is ...
10 years, 1 month ago (2010-11-02 17:18:54 UTC) #3
whywhat
+Scott for yet another pair of eyes :)
10 years, 1 month ago (2010-11-02 17:42:57 UTC) #4
DaveMoore
LGTM.
10 years, 1 month ago (2010-11-02 17:45:22 UTC) #5
sky
I haven't seen this code before, and as its multi-threaded it'll take me a while ...
10 years, 1 month ago (2010-11-02 17:51:58 UTC) #6
whywhat
10 years, 1 month ago (2010-11-02 19:10:58 UTC) #7
I'm okay with Dave's LGTM. Thanks for reviewing anyway, Scott!

http://codereview.chromium.org/4228002/diff/4001/5001
File chrome/browser/chromeos/login/camera.cc (right):

http://codereview.chromium.org/4228002/diff/4001/5001#newcode129
chrome/browser/chromeos/login/camera.cc:129: Lock Camera::image_lock_;
On 2010/11/02 17:51:58, sky wrote:
> Style guide says no static objects, use a pointer instead.

Done.

Powered by Google App Engine
This is Rietveld 408576698