From 6e81ca91fa8e62ca6fb5ba41c45bbd6a605d514c Mon Sep 17 00:00:00 2001 From: Stéphane Aulery Date: Sat, 8 Nov 2014 18:00:26 +0100 Subject: Fix cppcheck warning %d in format string requires 'int' but the argument type is 'unsigned int' MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Aulery Signed-off-by: Gerd Hoffmann --- wr/write-ps.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'wr') diff --git a/wr/write-ps.c b/wr/write-ps.c index 914a896..ee34988 100644 --- a/wr/write-ps.c +++ b/wr/write-ps.c @@ -415,20 +415,20 @@ ps_write(FILE *fp, struct ida_image *img) fprintf(fp,header, /* includes bbox */ xoff,yoff,xoff+width,yoff+height); fprintf(fp,"\n" - "/pix %d string def\n" - "/grays %d string def\n" + "/pix %u string def\n" + "/grays %u string def\n" "/npixls 0 def\n" "/rgbindx 0 def\n" "\n", img->i.width*3,img->i.width); fwrite(ColorImage,strlen(ColorImage),1,fp); - fprintf(fp,"%d %d translate\n",xoff,yoff); - fprintf(fp,"%d %d scale\n",width,height); + fprintf(fp,"%u %u translate\n",xoff,yoff); + fprintf(fp,"%u %u scale\n",width,height); fprintf(fp,"\n" - "%d %d 8\n" - "[%d 0 0 -%d 0 %d]\n" + "%u %u 8\n" + "[%u 0 0 -%u 0 %u]\n" "{currentfile pix readhexstring pop}\n" "false 3 colorimage\n", iwidth,iheight,iwidth,iheight,iheight); -- cgit