[GDIPLUS] Sync with Wine Staging 1.7.47. CORE-9924
[reactos.git] / reactos / dll / win32 / gdiplus / metafile.c
index 5d2cf49..4f82341 100644 (file)
@@ -1105,10 +1105,11 @@ GpStatus WINGDIPAPI GdipConvertToEmfPlus(const GpGraphics* ref,
     TRACE("(%p,%p,%p,%u,%s,%p)\n", ref, metafile, succ, emfType,
         debugstr_w(description), out_metafile);
 
-    if(!ref || !metafile || !out_metafile)
+    if(!ref || !metafile || !out_metafile || emfType < EmfTypeEmfOnly || emfType > EmfTypeEmfPlusDual)
         return InvalidParameter;
 
-    *succ = FALSE;
+    if(succ)
+        *succ = FALSE;
     *out_metafile = NULL;
 
     if(!(calls++))