Re: gdi32 : Correction of bug 20850 Write buffer overflow in WidenPath()

2009-11-29 Thread Laurent
On Sun, Nov 29, 2009 at 2:24 PM, Dan Kegel wrote: > On Sun, Nov 29, 2009 at 12:10 AM, Laurent wrote: >> Yes, it would be. The fact is that makes a zero byte size HeapAlloc. >> I'm not really sure how and why it is supposed to work in this case, > > It works fine, HeapReAlloc handles it ok, too. >

Re: gdi32 : Correction of bug 20850 Write buffer overflow in WidenPath()

2009-11-29 Thread Dan Kegel
On Sun, Nov 29, 2009 at 12:10 AM, Laurent wrote: > Yes, it would be. The fact is that makes a zero byte size HeapAlloc. > I'm not really sure how and why it is supposed to work in this case, It works fine, HeapReAlloc handles it ok, too. On Windows, it actually returns a heap block. (On Posix, it

Re: gdi32 : Correction of bug 20850 Write buffer overflow in WidenPath()

2009-11-29 Thread Nikolay Sivov
Laurent wrote: On Sun, Nov 29, 2009 at 2:32 AM, Dan Kegel wrote: On Sat, Nov 28, 2009 at 5:04 PM, Laurent Vromman wrote: -pStrokes = HeapAlloc(GetProcessHeap(), 0, numStrokes * sizeof(GdiPath*)); -pStrokes[0] = HeapAlloc(GetProcessHeap(), 0, sizeof(GdiPath)); -PATH_InitGdi

Re: gdi32 : Correction of bug 20850 Write buffer overflow in WidenPath()

2009-11-29 Thread Laurent
On Sun, Nov 29, 2009 at 2:32 AM, Dan Kegel wrote: > On Sat, Nov 28, 2009 at 5:04 PM, Laurent Vromman wrote: >> -    pStrokes = HeapAlloc(GetProcessHeap(), 0, numStrokes * >> sizeof(GdiPath*)); >> -    pStrokes[0] = HeapAlloc(GetProcessHeap(), 0, sizeof(GdiPath)); >> -    PATH_InitGdiPath(pStrokes

Re: gdi32 : Correction of bug 20850 Write buffer overflow in WidenPath()

2009-11-28 Thread Dan Kegel
On Sat, Nov 28, 2009 at 5:04 PM, Laurent Vromman wrote: > -    pStrokes = HeapAlloc(GetProcessHeap(), 0, numStrokes * > sizeof(GdiPath*)); > -    pStrokes[0] = HeapAlloc(GetProcessHeap(), 0, sizeof(GdiPath)); > -    PATH_InitGdiPath(pStrokes[0]); > -    pStrokes[0]->pFlags = HeapAlloc(GetProcessHe