summaryrefslogtreecommitdiffstats
path: root/backend_mitsu9550.c
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2018-09-30 09:24:48 -0400
committerSolomon Peachy <pizza@shaftnet.org>2018-09-30 09:24:48 -0400
commitf9c688176a06f2878a61c92c2aa9e4df134822e3 (patch)
tree1b3c290044b4239db038c5f6da20eedc8c1ca01e /backend_mitsu9550.c
parent473a0339a9e7cf3edd56f2ad15899c1f689bd104 (diff)
downloadselphy_print-f9c688176a06f2878a61c92c2aa9e4df134822e3.tar.gz
selphy_print-f9c688176a06f2878a61c92c2aa9e4df134822e3.tar.bz2
selphy_print-f9c688176a06f2878a61c92c2aa9e4df134822e3.zip
mitsu9xxx: Fix uninitalized read in 98xx gamma correction code.
Diffstat (limited to 'backend_mitsu9550.c')
-rw-r--r--backend_mitsu9550.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/backend_mitsu9550.c b/backend_mitsu9550.c
index b898c5a..923f6bd 100644
--- a/backend_mitsu9550.c
+++ b/backend_mitsu9550.c
@@ -1257,7 +1257,7 @@ static int mitsu9550_main_loop(void *vctx, const void *vjob) {
newlen += planelen;
/* And finally, the job footer. */
- memcpy(newbuf + newlen, job->databuf + sizeof(struct mitsu9550_plane) + planelen * 3, sizeof(struct mitsu9550_cmd));
+ memcpy(newbuf + newlen, job->databuf + sizeof(struct mitsu9550_plane) + planelen/2 * 3, sizeof(struct mitsu9550_cmd));
newlen += sizeof(struct mitsu9550_cmd);
/* Clean up, and move pointer to new buffer; */
@@ -1738,7 +1738,7 @@ static const char *mitsu9550_prefixes[] = {
/* Exported */
struct dyesub_backend mitsu9550_backend = {
.name = "Mitsubishi CP9xxx family",
- .version = "0.42",
+ .version = "0.43",
.uri_prefixes = mitsu9550_prefixes,
.cmdline_usage = mitsu9550_cmdline,
.cmdline_arg = mitsu9550_cmdline_arg,