displays the offending byte when something is wrong in the

window descriptor block.
merge-requests/1/head
Oliver Schirrmeister 2003-03-10 12:38:36 +00:00
rodzic b743fe4641
commit 711bb118b4
3 zmienionych plików z 22 dodań i 1 usunięć

Wyświetl plik

@ -1,3 +1,9 @@
2003-03-10 Oliver Schirrmeister <oschirr@abm.de>
* backend/fujitsu.c backund/fujitsu-scsi.h
displays the offending byte when something is wrong in the
window descriptor block.
2003-03-09 Eddy De Greef <eddy_de_greef at tiscali dot be>
* backend/mustek_pp_cis.c backend/mustek_pp_cis.h: Fixed two

Wyświetl plik

@ -933,7 +933,8 @@ static scsiblk window_descriptor_blockB =
#define get_RS_additional_length(b) b[0x07] /* always 10 */
#define get_RS_ASC(b) b[0x0c]
#define get_RS_ASCQ(b) b[0x0d]
#define get_RS_SKSV(b) getbitfield(b+0x0f,1,7) /* valid, always 0 */
#define get_RS_SKSV(b) getbitfield(b+0x0f,1,7) /* valid, always 0 */
#define get_RS_offending_byte(b) getnbyte(b+0x10, 2)
#define rs_return_block_size 18 /* Says Nikon */

Wyświetl plik

@ -89,6 +89,9 @@
- renamed some variables
- bugfix: duplex scanning now works when disconnect is enabled
in the scsi controller.
V 1.7, 10-Mar-2003 (oschirr@abm.de)
- displays the offending byte when something is wrong in the
window descriptor block.
SANE FLOW DIAGRAM
@ -2678,8 +2681,19 @@ scsi_sense_handler (int scsi_fd, u_char * sensed_data, void *arg)
}
else if ((0x26 == asc) && (0x00 == ascq))
{
DBG (MSG_ERR, "\t%d/%d/%d: Invalid field in parm list \n",
sense, asc, ascq);
/*hexdump (MSG_IO, "Sense", sensed_data, sensed_data[7]+8);*/
if (sensed_data[7]+8 >=17)
{
DBG(MSG_ERR,
"offending byte is %d. (Byte %d in window descriptor block)\n",
get_RS_offending_byte(sensed_data),
get_RS_offending_byte(sensed_data)-8);
}
ret = SANE_STATUS_INVAL;
}
else if ((0x2C == asc) && (0x02 == ascq))