gdiplus: Set result to NULL when CreatePathGradient fails.

This commit is contained in:
Vincent Povirk 2010-06-19 17:17:11 -05:00 committed by Alexandre Julliard
parent 1c41470cd0
commit 0e06326f5d

View file

@ -579,6 +579,7 @@ GpStatus WINGDIPAPI GdipCreatePathGradient(GDIPCONST GpPointF* points,
GdipFree((*grad)->blendfac);
GdipFree((*grad)->blendpos);
GdipFree(*grad);
*grad = NULL;
return OutOfMemory;
}
(*grad)->blendfac[0] = 1.0;
@ -672,6 +673,7 @@ GpStatus WINGDIPAPI GdipCreatePathGradientFromPath(GDIPCONST GpPath* path,
GdipFree((*grad)->blendfac);
GdipFree((*grad)->blendpos);
GdipFree(*grad);
*grad = NULL;
return OutOfMemory;
}
(*grad)->blendfac[0] = 1.0;