From 95e5fdd296e33da21711ba349c589aba81fbe799 Mon Sep 17 00:00:00 2001 From: giraffedata Date: Mon, 1 Jan 2024 18:42:37 +0000 Subject: cleanup git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@4833 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- converter/other/pamtogif.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/converter/other/pamtogif.c b/converter/other/pamtogif.c index bc89607d..4b609b5c 100644 --- a/converter/other/pamtogif.c +++ b/converter/other/pamtogif.c @@ -1530,18 +1530,18 @@ writeGifStreamTerminator(FILE * const ofP) { static void -writeGifImage(struct pam * const pamP, - FILE * const ofP, - pm_filepos const rasterPos, - bool const gInterlace, - int const background, - unsigned int const bitsPerPixel, - struct Cmap * const cmapP, - char const comment[], - float const aspect, - bool const lzw, - bool const noclear, - bool const usingAlpha) { +writeGif(struct pam * const pamP, + FILE * const ofP, + pm_filepos const rasterPos, + bool const gInterlace, + int const background, + unsigned int const bitsPerPixel, + struct Cmap * const cmapP, + char const comment[], + float const aspect, + bool const lzw, + bool const noclear, + bool const usingAlpha) { /*---------------------------------------------------------------------------- 'usingAlpha' means use the alpha (transparency) plane, if there is one, to determine which GIF pixels are transparent. When this is true, the @@ -1588,6 +1588,8 @@ writeGifImage(struct pam * const pamP, rowReader_destroy(rowReaderP); writeEndOfImage(ofP); + + writeGifStreamTerminator(ofP); } @@ -2054,15 +2056,13 @@ main(int argc, const char ** argv) { computeTransparent(transType, cmdline.transparent, fakeTransparent, &cmap); - writeGifImage(&pam, stdout, rasterPos, - cmdline.interlace, 0, bitsPerPixel, &cmap, cmdline.comment, - cmdline.aspect, !cmdline.nolzw, cmdline.noclear, - transType==TRANS_ALPHA); + writeGif(&pam, stdout, rasterPos, + cmdline.interlace, 0, bitsPerPixel, &cmap, cmdline.comment, + cmdline.aspect, !cmdline.nolzw, cmdline.noclear, + transType==TRANS_ALPHA); destroyCmap(&cmap); - writeGifStreamTerminator(stdout); - pm_close(ifP); pm_close(stdout); -- cgit 1.4.1