Prevent printer closing when a job is closed

It prevents future job to print
This commit is contained in:
ddoe 2024-03-04 14:05:32 +01:00 committed by akallabeth
parent 3b108f1839
commit d590b67ac4

View File

@ -136,7 +136,7 @@ static void printer_win_close_printjob(rdpPrintJob* printjob)
{
}
if (!ClosePrinter(win_printer->hPrinter))
if (!EndDocPrinter(win_printer->hPrinter))
{
}
@ -208,6 +208,9 @@ static void printer_win_free_printer(rdpPrinter* printer)
if (win_printer->printjob)
win_printer->printjob->printjob.Close((rdpPrintJob*)win_printer->printjob);
if (win_printer->hPrinter)
ClosePrinter(win_printer->hPrinter);
if (printer->backend)
printer->backend->ReleaseRef(printer->backend);