[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: [v4 PATCH] comctl32/tooltip: Protect TTM_ADDTOOLW from invalid text pointers
From:       Alexandre Julliard <julliard () winehq ! org>
Date:       2016-02-29 12:57:43
Message-ID: 87bn6zfzco.fsf () winehq ! org
[Download RAW message or body]

Alistair Leslie-Hughes <leslie_alistair@hotmail.com> writes:

> @@ -1041,6 +1041,9 @@ TOOLTIPS_AddToolT (TOOLTIPS_INFO *infoPtr, const TTTOOLINFOW *ti, BOOL isW)
>      if (ti->cbSize >= TTTOOLINFOW_V2_SIZE && !ti->lpszText && isW)
>          return FALSE;
>  
> +    if(isW && ti->lpszText && IsBadReadPtr(ti->lpszText, sizeof(WCHAR)))
> +        return FALSE;

You want IsBadStringPtrW, and this should most likely be merged with the
check above it one way or another.

-- 
Alexandre Julliard
julliard@winehq.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic