Implement StringFromGUID2 natively in Chromium
This change implements StringFromGUID2 natively in Chromium in order to
avoid calling into ole32.dll. This is necessary to support the effort to
delayload user32.dll and gdi32.dll because StringFromGUID2 has some
callers in the renderer process and delayloading ole32.dll for this
method call will cause the process to crash.
Bug: 948829
Change-Id: I00a2d5735984268813ecccc43aa3cb464d21c62c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1575869
Commit-Queue: Cliff Smolinsky <[email protected]>
Reviewed-by: Scott Violet <[email protected]>
Reviewed-by: Reilly Grant <[email protected]>
Reviewed-by: Tommi <[email protected]>
Reviewed-by: Misha Efimov <[email protected]>
Reviewed-by: Greg Thompson <[email protected]>
Reviewed-by: Bruce Dawson <[email protected]>
Cr-Commit-Position: refs/heads/master@{#654978}
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index 9481e9a..56b5e69 100644
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -728,6 +728,28 @@
True,
(),
),
+ (
+ 'StringFromGUID2',
+ (
+ 'StringFromGUID2 introduces an unnecessary dependency on ole32.dll.',
+ 'Use base::win::String16FromGUID instead.'
+ ),
+ True,
+ (
+ r'/base/win/win_util_unittest.cc'
+ ),
+ ),
+ (
+ 'StringFromCLSID',
+ (
+ 'StringFromCLSID introduces an unnecessary dependency on ole32.dll.',
+ 'Use base::win::String16FromGUID instead.'
+ ),
+ True,
+ (
+ r'/base/win/win_util_unittest.cc'
+ ),
+ ),
)