diff --git a/ChangeLog b/ChangeLog index 8160db407..d17362711 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,10 +4,11 @@ Fix warnings about ignored --datarootdir * backend/hp5590_low.c: Fix incompatible pointer type warning * backend/genesys_gl646.c: Fix incompatible pointer type warning - * backend/dc25.c, backend/epson2.c, backend/epson2-commands.c, - backend/epson2-io.c, backend/epson2_net.c, backend/genesys.c, - backend/genesys_gl841.c, backend/hp3900_usb.c, backend/lexmark_low.c, - backend/plustek-usbhw.c, backend/sm3840.c: Fix format warnings + * backend/dc25.c, backend/coolscan2.c, backend/epson2.c, + backend/epson2-commands.c, backend/epson2-io.c, backend/epson2_net.c, + backend/genesys.c, backend/genesys_gl841.c, backend/hp3900_usb.c, + backend/lexmark_low.c, backend/plustek-usbhw.c, backend/sm3840.c: + Fix format warnings * backend/pixma.c: Add missing #include 2008-02-02 Mattias Ellert diff --git a/backend/coolscan2.c b/backend/coolscan2.c index 003ed901c..2f597bf7a 100644 --- a/backend/coolscan2.c +++ b/backend/coolscan2.c @@ -1525,7 +1525,7 @@ sane_read (SANE_Handle h, SANE_Byte * buf, SANE_Int maxlen, SANE_Int * len) xfer_len_in += s->block_padding; i = (xfer_len_in & 0x3f); if (i != 0) - DBG (1, "BUG: sane_read(): Read size is not a multiple of 64. (0x%06x)\n", i); + DBG (1, "BUG: sane_read(): Read size is not a multiple of 64. (0x%06lx)\n", (long) i); } if (s->xfer_position + xfer_len_line > s->xfer_bytes_total) diff --git a/backend/epson2-commands.c b/backend/epson2-commands.c index 626893ca7..ba837e0fa 100644 --- a/backend/epson2-commands.c +++ b/backend/epson2-commands.c @@ -335,18 +335,18 @@ esci_request_extended_identity(SANE_Handle handle, unsigned char *buf) return status; DBG(1, " command level : %c%c\n", buf[0], buf[1]); - DBG(1, " basic resolution: %lu\n", le32atoh(&buf[4])); - DBG(1, " min resolution : %lu\n", le32atoh(&buf[8])); - DBG(1, " max resolution : %lu\n", le32atoh(&buf[12])); - DBG(1, " max pixel num : %lu\n", le32atoh(&buf[16])); + DBG(1, " basic resolution: %lu\n", (u_long) le32atoh(&buf[4])); + DBG(1, " min resolution : %lu\n", (u_long) le32atoh(&buf[8])); + DBG(1, " max resolution : %lu\n", (u_long) le32atoh(&buf[12])); + DBG(1, " max pixel num : %lu\n", (u_long) le32atoh(&buf[16])); DBG(1, " scan area : %lux%lu\n", - le32atoh(&buf[20]), le32atoh(&buf[24])); + (u_long) le32atoh(&buf[20]), (u_long) le32atoh(&buf[24])); DBG(1, " adf area : %lux%lu\n", - le32atoh(&buf[28]), le32atoh(&buf[32])); + (u_long) le32atoh(&buf[28]), (u_long) le32atoh(&buf[32])); DBG(1, " tpu area : %lux%lu\n", - le32atoh(&buf[36]), le32atoh(&buf[40])); + (u_long) le32atoh(&buf[36]), (u_long) le32atoh(&buf[40])); DBG(1, " main status : 0x%02x\n", buf[44]); DBG(1, " input depth : %d\n", buf[66]); @@ -507,12 +507,12 @@ esci_set_scanning_parameter(SANE_Handle handle, unsigned char *buf) params[0] = FS; params[1] = 'W'; - DBG(10, "resolution of main scan : %lu\n", le32atoh(&buf[0])); - DBG(10, "resolution of sub scan : %lu\n", le32atoh(&buf[4])); - DBG(10, "offset length of main scan : %lu\n", le32atoh(&buf[8])); - DBG(10, "offset length of sub scan : %lu\n", le32atoh(&buf[12])); - DBG(10, "scanning length of main scan: %lu\n", le32atoh(&buf[16])); - DBG(10, "scanning length of sub scan : %lu\n", le32atoh(&buf[20])); + DBG(10, "resolution of main scan : %lu\n", (u_long) le32atoh(&buf[0])); + DBG(10, "resolution of sub scan : %lu\n", (u_long) le32atoh(&buf[4])); + DBG(10, "offset length of main scan : %lu\n", (u_long) le32atoh(&buf[8])); + DBG(10, "offset length of sub scan : %lu\n", (u_long) le32atoh(&buf[12])); + DBG(10, "scanning length of main scan: %lu\n", (u_long) le32atoh(&buf[16])); + DBG(10, "scanning length of sub scan : %lu\n", (u_long) le32atoh(&buf[20])); DBG(10, "scanning color : %d\n", buf[24]); DBG(10, "data format : %d\n", buf[25]); DBG(10, "option control : %d\n", buf[26]); diff --git a/backend/epson2-io.c b/backend/epson2-io.c index 2276cb629..e720d07b6 100644 --- a/backend/epson2-io.c +++ b/backend/epson2-io.c @@ -117,7 +117,7 @@ e2_recv(Epson_Scanner * s, void *buf, ssize_t buf_size, { ssize_t n = 0; - DBG(15, "%s: size = %d, buf = %p\n", __func__, buf_size, buf); + DBG(15, "%s: size = %ld, buf = %p\n", __func__, (long) buf_size, buf); if (s->hw->connection == SANE_EPSON_NET) { n = sanei_epson_net_read(s, buf, buf_size, status); diff --git a/backend/epson2.c b/backend/epson2.c index 1bb2d03b2..163ec898f 100644 --- a/backend/epson2.c +++ b/backend/epson2.c @@ -3817,9 +3817,9 @@ e2_start_ext_scan(Epson_Scanner * s) s->ext_counter = 0; DBG(5, " status : 0x%02x\n", buf[1]); - DBG(5, " block size : %lu\n", le32atoh(&buf[2])); - DBG(5, " block count : %lu\n", le32atoh(&buf[6])); - DBG(5, " last block size: %lu\n", le32atoh(&buf[10])); + DBG(5, " block size : %lu\n", (u_long) le32atoh(&buf[2])); + DBG(5, " block count : %lu\n", (u_long) le32atoh(&buf[6])); + DBG(5, " last block size: %lu\n", (u_long) le32atoh(&buf[10])); if (s->ext_last_len) { s->ext_blocks++;