<div dir="ltr">Thanks. That's a good point. In Windows, GdipEnumerateMetafileSrcRectDestRectI is defined in gdiplusflat.h as  : <br>GpStatus WINGDIPAPI<br>GdipEnumerateMetafileSrcRectDestRectI(<br>    GpGraphics *            graphics,<br>    GDIPCONST GpMetafile *  metafile,<br>    GDIPCONST Rect &        destRect,<br>    GDIPCONST Rect &        srcRect,<br>    Unit                    srcUnit,<br>    EnumerateMetafileProc   callback,<br>    VOID *                  callbackData,<br>    GDIPCONST GpImageAttributes *     imageAttributes); <br><br><div>it means the arguments normally cannot be null because the compiler would block. </div><div>We could call the function with null value of two arguments when we use GetProcAddress. </div><div>In that case, the program gets a crash in Windows. if a developer made a SEH block, the program should go to the exception handler. </div><div>So, I think we should not check for null pointers to make it work the same. </div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">2021년 5월 17일 (월) 오전 1:06, Esme Povirk (they/them) <<a href="mailto:esme@codeweavers.com">esme@codeweavers.com</a>>님이 작성:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">We should check if destRect or srcRect are NULL before dereferencing<br>
them. Based on the float version, a NULL destRect should result in an<br>
InvalidParameter return, and a NULL srcRect should be passed through<br>
as NULL.<br>
</blockquote></div>