Skip to content

Commit

Permalink
dplayx: Check the message size before access.
Browse files Browse the repository at this point in the history
  • Loading branch information
baskanov authored and julliard committed Sep 20, 2024
1 parent e029eb6 commit da5d8ff
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dlls/dplayx/dplaysp.c
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,9 @@ static HRESULT WINAPI IDirectPlaySPImpl_HandleMessage( IDirectPlaySP *iface, voi
FIXME( "(%p)->(%p,0x%08lx,%p): mostly stub\n",
This, lpMessageBody, dwMessageBodySize, lpMessageHeader );

if ( dwMessageBodySize < sizeof( DPMSG_SENDENVELOPE ) )
return DPERR_GENERIC;

wCommandId = lpMsg->wCommandId;
wVersion = lpMsg->wVersion;

Expand Down

0 comments on commit da5d8ff

Please sign in to comment.