From 66520042a40f358f67d4a65550ffb2d34ff54914 Mon Sep 17 00:00:00 2001 From: Philipp Klaus Date: Sat, 12 Dec 2015 16:56:37 +0100 Subject: [PATCH 1/2] string.h needed for memset with newer gcc --- ql570.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ql570.c b/ql570.c index c28fb78..292e12f 100644 --- a/ql570.c +++ b/ql570.c @@ -16,6 +16,7 @@ #include #include #include +#include #define PNG_DEBUG 3 #include From cd97c1e5afd9eeb59ab270e7397d3c7a6d649194 Mon Sep 17 00:00:00 2001 From: Philipp Klaus Date: Sat, 12 Dec 2015 16:58:17 +0100 Subject: [PATCH 2/2] Fixing expanded / cut every commands: use all fprintf args --- ql570.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ql570.c b/ql570.c index 292e12f..1699016 100644 --- a/ql570.c +++ b/ql570.c @@ -94,10 +94,10 @@ void ql570_print(pngdata_t * img, unsigned int paper_width) } /* Set cut type */ - fprintf(fp, "%c%c%c", ESC, 'i', 'K', 8); + fprintf(fp, "%c%c%c%c", ESC, 'i', 'K', 8); /* Enable cutter */ - fprintf(fp, "%c%c%c", ESC, 'i', 'A', 1); + fprintf(fp, "%c%c%c%c", ESC, 'i', 'A', 1); /* Set margin = 0 */ fprintf(fp, "%c%c%c%c%c", ESC, 'i', 'd', 0, 0);