summaryrefslogtreecommitdiffstats
path: root/base/win/win_util.cc
diff options
context:
space:
mode:
authorsanjeevr@chromium.org <sanjeevr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-25 19:00:41 +0000
committersanjeevr@chromium.org <sanjeevr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-02-25 19:00:41 +0000
commit5f86d6ffe9722dafa98bc5b068962de4533e0130 (patch)
tree8aaa2f8b9839f7e07cc388a59aa3760849fc7b92 /base/win/win_util.cc
parente34b6f3a2a024060d59fb7585a4a497a7aa2cf26 (diff)
downloadchromium_src-5f86d6ffe9722dafa98bc5b068962de4533e0130.zip
chromium_src-5f86d6ffe9722dafa98bc5b068962de4533e0130.tar.gz
chromium_src-5f86d6ffe9722dafa98bc5b068962de4533e0130.tar.bz2
Removed the command line from ServiceProcessState::AddToAutoRun() and had the class calculate its own command line. Wired up Linux autorun code and added unit tests.
BUG=None TEST=Test service process autorun when enabling the cloud print proxy, unit-tests. Review URL: http://codereview.chromium.org/6591002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76077 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/win/win_util.cc')
-rw-r--r--base/win/win_util.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/base/win/win_util.cc b/base/win/win_util.cc
index d3d74a2..76d8c5d 100644
--- a/base/win/win_util.cc
+++ b/base/win/win_util.cc
@@ -137,6 +137,13 @@ bool RemoveCommandFromAutoRun(HKEY root_key, const string16& name) {
return (autorun_key.DeleteValue(name.c_str()) == ERROR_SUCCESS);
}
+bool ReadCommandFromAutoRun(HKEY root_key,
+ const string16& name,
+ string16* command) {
+ base::win::RegKey autorun_key(root_key, kAutoRunKeyPath, KEY_QUERY_VALUE);
+ return (autorun_key.ReadValue(name.c_str(), command) == ERROR_SUCCESS);
+}
+
} // namespace win
} // namespace base