windows.cfg: Fix PostMessage() configuration
First argument is optional (allowed to be NULL). See also the annotation "_In_opt_". Reference: https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-postmessagea
This commit is contained in:
parent
5bf6bd1f5e
commit
d08539fe17
|
@ -2738,15 +2738,30 @@ HFONT CreateFont(
|
||||||
_In_ UINT Msg,
|
_In_ UINT Msg,
|
||||||
_In_ WPARAM wParam,
|
_In_ WPARAM wParam,
|
||||||
_In_ LPARAM lParam); -->
|
_In_ LPARAM lParam); -->
|
||||||
|
<function name="SendMessage,SendMessageA,SendMessageW">
|
||||||
|
<noreturn>false</noreturn>
|
||||||
|
<arg nr="1" direction="in">
|
||||||
|
<not-null/>
|
||||||
|
<not-uninit/>
|
||||||
|
</arg>
|
||||||
|
<arg nr="2" direction="in">
|
||||||
|
<not-uninit/>
|
||||||
|
</arg>
|
||||||
|
<arg nr="3" direction="in">
|
||||||
|
<not-uninit/>
|
||||||
|
</arg>
|
||||||
|
<arg nr="4" direction="in">
|
||||||
|
<not-uninit/>
|
||||||
|
</arg>
|
||||||
|
</function>
|
||||||
<!-- BOOL WINAPI PostMessage(
|
<!-- BOOL WINAPI PostMessage(
|
||||||
_In_opt_ HWND hWnd,
|
_In_opt_ HWND hWnd,
|
||||||
_In_ UINT Msg,
|
_In_ UINT Msg,
|
||||||
_In_ WPARAM wParam,
|
_In_ WPARAM wParam,
|
||||||
_In_ LPARAM lParam); -->
|
_In_ LPARAM lParam); -->
|
||||||
<function name="SendMessage,SendMessageA,SendMessageW,PostMessage,PostMessageA,PostMessageW">
|
<function name="PostMessage,PostMessageA,PostMessageW">
|
||||||
<noreturn>false</noreturn>
|
<noreturn>false</noreturn>
|
||||||
<arg nr="1" direction="in">
|
<arg nr="1" direction="in">
|
||||||
<not-null/>
|
|
||||||
<not-uninit/>
|
<not-uninit/>
|
||||||
</arg>
|
</arg>
|
||||||
<arg nr="2" direction="in">
|
<arg nr="2" direction="in">
|
||||||
|
|
|
@ -190,6 +190,8 @@ void validCode()
|
||||||
void * pAlloc1 = _aligned_malloc(100, 2);
|
void * pAlloc1 = _aligned_malloc(100, 2);
|
||||||
_aligned_free(pAlloc1);
|
_aligned_free(pAlloc1);
|
||||||
|
|
||||||
|
::PostMessage(nullptr, WM_QUIT, 0, 0);
|
||||||
|
|
||||||
// Valid Library usage, no leaks, valid arguments
|
// Valid Library usage, no leaks, valid arguments
|
||||||
HINSTANCE hInstLib = LoadLibrary(L"My.dll");
|
HINSTANCE hInstLib = LoadLibrary(L"My.dll");
|
||||||
FreeLibrary(hInstLib);
|
FreeLibrary(hInstLib);
|
||||||
|
|
Loading…
Reference in New Issue