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

Issue 403018: linux: use /proc/self/exe when exec'ing ourselves (Closed)

Created:
11 years, 1 month ago by Evan Martin
Modified:
9 years, 7 months ago
Reviewers:
Lei Zhang, jam, agl
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

linux: use /proc/self/exe when exec'ing ourselves We don't want to ever go out to disk when looking for data after startup, since they can be changed by an update. We *should* just be using the zygote, but the zygote is sandboxed-only for now, and fixing that has a lengthy dependency graph. In the interim, /proc/self/exe is the correct executable and exec'ing it should work as long as the subprocess doesn't need any other files from the Chrome directory. BUG=22703 TEST=Start Chrome. Move away the entire Chrome directory; plugins should still work. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=32486

Patch Set 1 #

Patch Set 2 : wow #

Patch Set 3 : fixed test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+17 lines, -10 lines) Patch
M chrome/common/child_process_host.cc View 1 chunk +10 lines, -6 lines 0 comments Download
M chrome/common/chrome_constants.cc View 1 chunk +3 lines, -1 line 0 comments Download
M chrome/test/chrome_process_util.cc View 1 chunk +4 lines, -3 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Evan Martin
I am surprised that this seems to work for plugins, but it does!
11 years, 1 month ago (2009-11-18 20:50:22 UTC) #1
agl
(Note: the reason that we don't do this for everything is that the process will ...
11 years, 1 month ago (2009-11-18 20:55:06 UTC) #2
jam
sweet, lgtm
11 years, 1 month ago (2009-11-18 20:59:08 UTC) #3
Evan Martin
Please look again, I had to fix some tests that depend on the process name. ...
11 years, 1 month ago (2009-11-18 23:41:44 UTC) #4
agl
11 years, 1 month ago (2009-11-18 23:45:38 UTC) #5
LGTM

Powered by Google App Engine
This is Rietveld 408576698