Re: seg-faults for network access

From: Jochen Eisinger (jochen.eisinger@gno.de)
Date: Sun Dec 10 2000 - 05:43:42 PST

  • Next message: Mitsuru Okaniwa: "Re: The calibration function for CanoScanFB620S"

    Hi!

    little typo in the patch... sorry

    -- jochen

    > --- ../sane/sane-backends/sanei/sanei_wire.c Sat Aug 12 17:11:37 2000
    > +++ sane-backends/sanei/sanei_wire.c Sun Dec 10 12:38:19 2000
    > @@ -56,6 +56,9 @@
    > int fd = w->io.fd;
    > ssize_t nread, nwritten;
    >
    > + if (w->status != 0)
    > + return;
    > +
    > if (w->buffer.curr + howmuch > w->buffer.end)
    > {
    > switch (w->direction)
    > @@ -80,6 +83,8 @@
    >
    > case WIRE_DECODE:
    > left_over = w->buffer.end - w->buffer.curr;
    > + if ((signed) left_over < 0)
                             ^^^ too many brackets here

    > + return;
    > if (left_over)
    > memcpy (w->buffer.start, w->buffer.curr, left_over);
    > w->buffer.curr = w->buffer.start;

    --
    Source code, list archive, and docs: http://www.mostang.com/sane/
    To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com
    



    This archive was generated by hypermail 2b29 : Sun Dec 10 2000 - 05:42:06 PST