summaryrefslogtreecommitdiff
path: root/backend/epsonds.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2020-05-23 09:51:36 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2020-05-23 09:51:36 +0200
commit9c23ed018d72eed2554f4f9cff1ae6e6bb0cd479 (patch)
tree341ed14001deb0670a2b98b72039885c9a204dcf /backend/epsonds.c
parentffa8801644a7d53cc1c785e3450f794c07a14eb0 (diff)
New upstream version 1.0.30upstream/1.0.30
Diffstat (limited to 'backend/epsonds.c')
-rw-r--r--backend/epsonds.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/backend/epsonds.c b/backend/epsonds.c
index ff5d681..fb9694a 100644
--- a/backend/epsonds.c
+++ b/backend/epsonds.c
@@ -1230,16 +1230,18 @@ sane_start(SANE_Handle handle)
if (s->line_buffer == NULL)
return SANE_STATUS_NO_MEM;
- /* ring buffer for front page, twice bsz */
+ /* transfer buffer size, bsz */
/* XXX read value from scanner */
- status = eds_ring_init(&s->front, (65536 * 4) * 2);
+ s->bsz = (65536 * 4);
+
+ /* ring buffer for front page */
+ status = eds_ring_init(&s->front, s->bsz * 2);
if (status != SANE_STATUS_GOOD) {
return status;
}
- /* transfer buffer, bsz */
- /* XXX read value from scanner */
- s->buf = realloc(s->buf, 65536 * 4);
+ /* transfer buffer */
+ s->buf = realloc(s->buf, s->bsz);
if (s->buf == NULL)
return SANE_STATUS_NO_MEM;