[<<][pool][>>][..]
Mon Feb 28 17:37:38 EST 2011

Brother MFC-240C CUPS Linux driver bug

Long story short:
The error is: "No pages found!" when printing remotely.
Everything works fine locally.

The bug is a classic off-by-one error.  The fix is at the end of
/usr/lib/cups/filter/brlpdwrappermfc240c

-   if [ $# -ge 7 ]; then
+   if [ $# -ge 6 ]; then

When the 6th argument is zero, the input is expected on stdin.  When
it is not, the input is stored in a file.  Apparently for local
printing (and cups-lpr) the input is on stdin, and for remote it is in
a file.  Looks like this was simply not tested during driver debugging.

The error message in /var/log/cups/error_log:

D [28/Feb/2011:08:35:55 -0500] [Job 8] /usr/local/Brother/Printer/mfc240c/lpd/filtermfc240c: 60: a2ps: not found

is simply a consequence of the input being an empty file which itself
is a consequence of the "-ge 7" bug..  This empty file is then not
recognized and its contents is passed over to a2ps.


Context: this is on debian squeeze with the following Brother drivers:

# dpkg -l |grep 240
ii  mfc240ccupswrapper                            1.0.1-1                        Brother CUPS Inkjet Printer Definitions
ii  mfc240clpr                                    1.0.1-1                        Brother lpr Inkjet Printer Definitions

And this cups version:

# dpkg -l |grep cups
ii  cups                                          1.4.4-7                        Common UNIX Printing System(tm) - server
ii  cups-client                                   1.4.6-1                        Common UNIX Printing System(tm) - client programs (SysV)
ii  cups-common                                   1.4.6-1                        Common UNIX Printing System(tm) - common files
ii  cups-driver-gutenprint                        5.2.6-1                        printer drivers for CUPS
ii  cups-ppdc                                     1.4.4-7                        Common UNIX Printing System(tm) - PPD manipulation utilities
ii  ghostscript-cups                              8.71~dfsg2-9                   The GPL Ghostscript PostScript/PDF interpreter - CUPS filters
ii  libcups2                                      1.4.4-7                        Common UNIX Printing System(tm) - Core library
ii  libcupscgi1                                   1.4.4-7                        Common UNIX Printing System(tm) - CGI library
ii  libcupsdriver1                                1.4.4-7                        Common UNIX Printing System(tm) - Driver library
ii  libcupsimage2                                 1.4.4-7                        Common UNIX Printing System(tm) - Raster image library
ii  libcupsmime1                                  1.4.4-7                        Common UNIX Printing System(tm) - MIME library
ii  libcupsppdc1                                  1.4.4-7                        Common UNIX Printing System(tm) - PPD manipulation library
ii  mfc240ccupswrapper                            1.0.1-1                        Brother CUPS Inkjet Printer Definitions



[Reply][About]
[<<][pool][>>][..]