Commit 592f8e1b authored by brucedawson's avatar brucedawson Committed by Commit bot

Fix return type of SetProcessDpiAwareness aka SetProcessDpiAwarenessInternal

This function (documented as SetProcessDpiAwareness but exported as
SetProcessDpiAwarenessInternal) has a return type of HRESULT but we
declared it as returning BOOL. This triggered the following /analyze
warning:

src\chrome\app\chrome_exe_main_win.cc(104) : warning C6216:
   Compiler-inserted cast between semantically different integral
   types:  a Boolean type to HRESULT.

BUG=427616

Review URL: https://codereview.chromium.org/691903002

Cr-Commit-Position: refs/heads/master@{#302212}
parent e6b58b5a
......@@ -95,7 +95,7 @@ typedef enum MONITOR_DPI_TYPE {
// Win8.1 supports monitor-specific DPI scaling.
bool SetProcessDpiAwarenessWrapper(PROCESS_DPI_AWARENESS value) {
typedef BOOL(WINAPI *SetProcessDpiAwarenessPtr)(PROCESS_DPI_AWARENESS);
typedef HRESULT(WINAPI *SetProcessDpiAwarenessPtr)(PROCESS_DPI_AWARENESS);
SetProcessDpiAwarenessPtr set_process_dpi_awareness_func =
reinterpret_cast<SetProcessDpiAwarenessPtr>(
GetProcAddress(GetModuleHandleA("user32.dll"),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment