From fcb6ae29a6ee45a5a0e4e41dd8785c6ad5c921f9 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Fri, 15 Oct 2021 16:54:04 +0200 Subject: [PATCH] win32u: Don't call abort proc in NtGdiStartDoc. It's called by StartDocW. Signed-off-by: Jacek Caban Signed-off-by: Huw Davies Signed-off-by: Alexandre Julliard --- dlls/win32u/printdrv.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/dlls/win32u/printdrv.c b/dlls/win32u/printdrv.c index 37f5817c62f..6fb0d07cfb9 100644 --- a/dlls/win32u/printdrv.c +++ b/dlls/win32u/printdrv.c @@ -68,22 +68,19 @@ DWORD WINAPI NtGdiInitSpool(void) */ INT WINAPI NtGdiStartDoc( HDC hdc, const DOCINFOW *doc, BOOL *banding, INT job ) { - INT ret; + INT ret = SP_ERROR; DC *dc = get_dc_ptr( hdc ); TRACE("DocName %s, Output %s, Datatype %s, fwType %#x\n", debugstr_w(doc->lpszDocName), debugstr_w(doc->lpszOutput), debugstr_w(doc->lpszDatatype), doc->fwType); - if(!dc) return SP_ERROR; - - if (dc->attr->abort_proc && !dc->attr->abort_proc( hdc, 0 )) ret = 0; - else + if (dc) { PHYSDEV physdev = GET_DC_PHYSDEV( dc, pStartDoc ); ret = physdev->funcs->pStartDoc( physdev, doc ); + release_dc_ptr( dc ); } - release_dc_ptr( dc ); return ret; }