Module: wine Branch: master Commit: 101bcc221d4a446aca3c959f5150757de9e5b88c URL: https://gitlab.winehq.org/wine/wine/-/commit/101bcc221d4a446aca3c959f5150757... Author: David Kahurani <k.kahurani(a)gmail.com> Date: Sun Jun 18 14:41:45 2023 +0300 gdiplus: Allow NULL format in GdipAddPathString. GdipAddPathString accepts NULL for format and presumably uses the default format for formating Signed-off-by: David Kahurani <k.kahurani(a)gmail.com> --- dlls/gdiplus/graphicspath.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c index 4da84a9eac5..ad4dde58ccd 100644 --- a/dlls/gdiplus/graphicspath.c +++ b/dlls/gdiplus/graphicspath.c @@ -1010,9 +1010,12 @@ GpStatus WINGDIPAPI GdipAddPathString(GpPath* path, GDIPCONST WCHAR* string, INT TEXTMETRICW textmetric; TRACE("(%p, %s, %d, %p, %d, %f, %p, %p)\n", path, debugstr_w(string), length, family, style, emSize, layoutRect, format); - if (!path || !string || !family || !emSize || !layoutRect || !format) + if (!path || !string || !family || !emSize || !layoutRect) return InvalidParameter; + if (!format) + format = &default_drawstring_format; + status = GdipGetEmHeight(family, style, &native_height); if (status != Ok) return status;