The following patch should fix the case mismatch.

-dave

--- hplip-0.9.10/io/hpiod/device.cpp.strcasecmp 2006-04-04
11:00:24.000000000 +0100
+++ hplip-0.9.10/io/hpiod/device.cpp    2006-04-04 11:00:40.000000000
+0100
@@ -633,7 +633,7 @@
    pSys->GeneralizeModel(sz, gen, sizeof(gen));
 
    pSys->GetURIModel(uri, uriModel, sizeof(uriModel));
-   if (strcmp(uriModel, gen) != 0)
+   if (strcasecmp(uriModel, gen) != 0)
       goto bugout;
 
    if (usb_get_string_simple(hd, dev->descriptor.iSerialNumber, sz,
sizeof(sz)) < 0)

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of 
> Anish Mistry
> Sent: Tuesday, April 04, 2006 4:46 PM
> To: hplip-devel@lists.sourceforge.net
> Subject: [HPLIP-Devel] Error with Printer Model Detection
> 
> 
> While trying to test out my other printers I found a problem with the 
> printer model check in device.cpp.  The following appeared in my 
> syslog when I tried to print to my Deskjet 920C.
> 
> Apr  4 19:20:45 bigguy hpiod: invalid model DeskJet_920C != 
> DESKJET_920C Device::Open io/hpiod/device.cpp 1139
> Apr  4 19:20:45 bigguy DeskJet_920C?serial=MX1CC6F1CHBI: INFO: open 
> device failed; will retry in 30 seconds...
> 
> I appears that the strcmp check should actually be a strcasecmp so 
> that it detects model matches without worrying about case.
> 
> -- 
> Anish Mistry
> [EMAIL PROTECTED]
> AM Productions http://am-productions.biz/
> 


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642
_______________________________________________
HPLIP-Devel mailing list
HPLIP-Devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hplip-devel

Reply via email to