Commit 5c58e448 authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

localspl: Add ReadPrinter implementation.

parent f4dbb3e8
...@@ -3476,6 +3476,21 @@ static BOOL WINAPI fpScheduleJob(HANDLE hprinter, DWORD job_id) ...@@ -3476,6 +3476,21 @@ static BOOL WINAPI fpScheduleJob(HANDLE hprinter, DWORD job_id)
return ret; return ret;
} }
static BOOL WINAPI fpReadPrinter(HANDLE hprinter, void *buf, DWORD size, DWORD *bytes_read)
{
job_t *job = (job_t *)hprinter;
TRACE("%p %p %lu %p\n", hprinter, buf, size, bytes_read);
if (!job || (job->header.type != HANDLE_JOB))
{
SetLastError(ERROR_INVALID_HANDLE);
return FALSE;
}
return ReadFile(job->hf, buf, size, bytes_read, NULL);
}
static BOOL WINAPI fpEndDocPrinter(HANDLE hprinter) static BOOL WINAPI fpEndDocPrinter(HANDLE hprinter)
{ {
printer_t *printer = (printer_t *)hprinter; printer_t *printer = (printer_t *)hprinter;
...@@ -3590,7 +3605,7 @@ static const PRINTPROVIDOR backend = { ...@@ -3590,7 +3605,7 @@ static const PRINTPROVIDOR backend = {
fpWritePrinter, fpWritePrinter,
NULL, /* fpEndPagePrinter */ NULL, /* fpEndPagePrinter */
NULL, /* fpAbortPrinter */ NULL, /* fpAbortPrinter */
NULL, /* fpReadPrinter */ fpReadPrinter,
fpEndDocPrinter, fpEndDocPrinter,
fpAddJob, fpAddJob,
fpScheduleJob, fpScheduleJob,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment