summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrobertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-02 20:25:49 +0000
committerrobertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-02 20:25:49 +0000
commit57b596fddc253be309dddd5ab2ddc62f5afa5c25 (patch)
tree4706184e03d347fbac4e2419fb8ba5600edddb75
parent2c22968fe57ea2f1e6a4e4d1fdca3c38d3dc483c (diff)
downloadchromium_src-57b596fddc253be309dddd5ab2ddc62f5afa5c25.zip
chromium_src-57b596fddc253be309dddd5ab2ddc62f5afa5c25.tar.gz
chromium_src-57b596fddc253be309dddd5ab2ddc62f5afa5c25.tar.bz2
Add dummy user-level registration entry points to the CEEE dlls. This allows user-level installation to complete without error.
Also fix the presubmit script to allow checkins to toolband_module.cc again (it was picking up DllRegisterServer members in a class declaration). Also add line number printing to the presubmit error message. BUG=62403 TEST=User-level installs of CF work again. Review URL: http://codereview.chromium.org/5539002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68058 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--ceee/ceee_presubmit.py6
-rw-r--r--ceee/ie/plugin/toolband/toolband.def10
-rw-r--r--ceee/ie/plugin/toolband/toolband_module.cc14
-rw-r--r--ceee/installer_dll/installer_helper.cc14
-rw-r--r--ceee/installer_dll/installer_helper.def10
5 files changed, 43 insertions, 11 deletions
diff --git a/ceee/ceee_presubmit.py b/ceee/ceee_presubmit.py
index 2bbdcbe..da90f8d 100644
--- a/ceee/ceee_presubmit.py
+++ b/ceee/ceee_presubmit.py
@@ -20,7 +20,7 @@ SOURCE_FILE_EXTENSIONS = [
EXCLUDED_PATHS = []
# Finds what seem to be definitions of DllRegisterServer.
-DLL_REGISTER_SERVER_RE = re.compile('\s+DllRegisterServer\s*\(')
+DLL_REGISTER_SERVER_RE = re.compile('\s*STDAPI\s+DllRegisterServer\s*\(')
# Matches a Tracker story URL
story_url_re = re.compile('https?://tracker.+/[0-9]+')
@@ -178,9 +178,9 @@ def CheckNoDllRegisterServer(input_api, output_api):
file_name = os.path.basename(f.LocalPath())
if file_name not in ['install_utils.h', 'install_utils_unittest.cc']:
return [output_api.PresubmitError(
- '%s seems to contain a definition of DllRegisterServer.\n'
+ '%s contains a definition of DllRegisterServer at line %s.\n'
'Please search for CEEE_DEFINE_DLL_REGISTER_SERVER.' %
- f.LocalPath())]
+ (f.LocalPath(), line_num))]
return []
diff --git a/ceee/ie/plugin/toolband/toolband.def b/ceee/ie/plugin/toolband/toolband.def
index 9c9cc5b..22aaa0f 100644
--- a/ceee/ie/plugin/toolband/toolband.def
+++ b/ceee/ie/plugin/toolband/toolband.def
@@ -7,7 +7,9 @@
LIBRARY "ceee_ie.DLL"
EXPORTS
- DllCanUnloadNow PRIVATE
- DllGetClassObject PRIVATE
- DllRegisterServer PRIVATE
- DllUnregisterServer PRIVATE
+ DllCanUnloadNow PRIVATE
+ DllGetClassObject PRIVATE
+ DllRegisterServer PRIVATE
+ DllRegisterUserServer PRIVATE
+ DllUnregisterServer PRIVATE
+ DllUnregisterUserServer PRIVATE
diff --git a/ceee/ie/plugin/toolband/toolband_module.cc b/ceee/ie/plugin/toolband/toolband_module.cc
index 6824542..6e99c97 100644
--- a/ceee/ie/plugin/toolband/toolband_module.cc
+++ b/ceee/ie/plugin/toolband/toolband_module.cc
@@ -145,6 +145,20 @@ HRESULT ToolbandModule::DllUnregisterServer() {
return hr;
}
+// No-op entry point to keep user-level registration happy.
+// TODO(robertshield): Remove this as part of registration re-org.
+STDAPI DllRegisterUserServer() {
+ LOG(WARNING) << "Call to unimplemented DllRegisterUserServer.";
+ return S_OK;
+}
+
+// No-op entry point to keep user-level unregistration happy.
+// TODO(robertshield): Remove this as part of registration re-org.
+STDAPI DllUnregisterUserServer() {
+ LOG(WARNING) << "Call to unimplemented DllUnregisterUserServer.";
+ return S_OK;
+}
+
void ToolbandModule::Init() {
// We must protect our data member against concurrent calls to check if we
// can be unloaded. We must also making the call to Term within the lock
diff --git a/ceee/installer_dll/installer_helper.cc b/ceee/installer_dll/installer_helper.cc
index 6ebc49a..01f5bd4 100644
--- a/ceee/installer_dll/installer_helper.cc
+++ b/ceee/installer_dll/installer_helper.cc
@@ -431,3 +431,17 @@ STDAPI DllUnregisterServer(void) {
return combined_result;
}
+
+// No-op entry point to keep user-level registration happy.
+// TODO(robertshield): Remove this as part of registration re-org.
+STDAPI DllRegisterUserServer() {
+ LOG(WARNING) << "Call to unimplemented DllRegisterUserServer.";
+ return S_OK;
+}
+
+// No-op entry point to keep user-level unregistration happy.
+// TODO(robertshield): Remove this as part of registration re-org.
+STDAPI DllUnregisterUserServer() {
+ LOG(WARNING) << "Call to unimplemented DllUnregisterUserServer.";
+ return S_OK;
+}
diff --git a/ceee/installer_dll/installer_helper.def b/ceee/installer_dll/installer_helper.def
index 5cbfee2..9190bb2 100644
--- a/ceee/installer_dll/installer_helper.def
+++ b/ceee/installer_dll/installer_helper.def
@@ -7,7 +7,9 @@
LIBRARY "ceee_installer_helper.DLL"
EXPORTS
- DllCanUnloadNow PRIVATE
- DllGetClassObject PRIVATE
- DllRegisterServer PRIVATE
- DllUnregisterServer PRIVATE
+ DllCanUnloadNow PRIVATE
+ DllGetClassObject PRIVATE
+ DllRegisterServer PRIVATE
+ DllRegisterUserServer PRIVATE
+ DllUnregisterServer PRIVATE
+ DllUnregisterUserServer PRIVATE