1 - Resolved
2 - Low, e.g. a documentation error or undocumented side-effect
3 - Applies to all machines and operating systems
The scheduler never gets the MIME type based on the document name for a single file job
Opher Shachar
Michael Sweet
1.3-current (SVN: r8221)


Login to Post

Jan 9, 2009 by Opher Shachar :
Attached file: document-name.patch

Jan 9, 2009 by Opher Shachar :
Please look at scheduler/ipp.c line 7637:
    doc_name = ippFindAttribute(con->request, "document-name", IPP_TAG_NAME);
    filetype = mimeFileType(MimeDatabase, con->filename,
                            doc_name ? doc_name->values[0].string.text : NULL,

The scheduler is looking for an attribute "document-name", BUT the client ONLY sends this attribute when printing more than one file per job:
in cups/util.c this attribute is sent in cupsPrintFiles2 ONLY when num_files > 1 .

Suggested patch attached.

Opher Shachar.

Jan 9, 2009 by Michael Sweet:
Attached file: str3055.patch

Jan 9, 2009 by Michael Sweet:
Fixed in Subversion repository.

(This actually was already fixed by the API changes in CUPS 1.4)

Login to Post