From 8ecd54e8d2d18d2a539d3625e7cf55df43570b0b Mon Sep 17 00:00:00 2001 From: Thierry HUCHARD Date: Sat, 14 Mar 2020 22:17:34 +0100 Subject: [PATCH] Add FormatExt for PDF. --- backend/escl/escl_newjob.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/backend/escl/escl_newjob.c b/backend/escl/escl_newjob.c index 084431cc3..5b52ec7e4 100644 --- a/backend/escl/escl_newjob.c +++ b/backend/escl/escl_newjob.c @@ -80,7 +80,10 @@ static char formatExtPNG[] = static char formatExtTIFF[] = " image/tiff"; -/** +static char formatExtPDF[] = + " application/pdf"; + + /** * \fn static size_t download_callback(void *str, size_t size, size_t nmemb, void *userp) * \brief Callback function that stocks in memory the content of the 'job'. Example below : * "Trying 192.168.14.150... @@ -173,6 +176,8 @@ escl_newjob (capabilities_t *scanner, SANE_String_Const name, SANE_Status *statu format_ext = formatExtPNG; else if (!strcmp(scanner->default_format, "image/tiff")) format_ext = formatExtTIFF; + else if (!strcmp(scanner->default_format, "application/pdf")) + format_ext = formatExtPDF; else format_ext = f_ext; }