From 2566de728869bb92f1a96ea789df3f17b65e6c03 Mon Sep 17 00:00:00 2001 From: sparky4 Date: Thu, 5 Nov 2015 14:52:00 -0600 Subject: [PATCH] attempted~ --- src/lib/modex16/planar16.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/lib/modex16/planar16.c b/src/lib/modex16/planar16.c index 2615d2de..3ed90c08 100755 --- a/src/lib/modex16/planar16.c +++ b/src/lib/modex16/planar16.c @@ -61,13 +61,12 @@ static void loadPcxStage1(FILE *file, planar_buf_t *result) { /* make sure this is 8bpp */ if(head.bpp != 8) { - printf("I only know how to handle 8bpp pcx files!\n"); + fprintf(stderr, "I only know how to handle 8bpp pcx files!\n"); fclose(file); - exit(-2); + //exit(-2); } } - static void loadPcxPalette(FILE *file, planar_buf_t *result) { byte val; int index; @@ -111,7 +110,7 @@ planar_buf_t planarLoadPcx(char *filename) loadPcxStage1(file, &result); /* allocate the buffer */ - bufSize = (/*(dword)*/result.pwidth * result.height); + bufSize = (/*(dword)*/result.width * result.height); result = *planar_buf_alloc(result.width, result.height); if(!result.plane[0]) { fprintf(stderr, "Could not allocate memory for bitmap data."); -- 2.39.5