From 5a66118f8b5630bf91cd8826cef7c5be48e70747 Mon Sep 17 00:00:00 2001 From: tth Date: Wed, 19 Feb 2020 22:32:24 +0100 Subject: [PATCH] nasty bug fixed in fimgfx --- tools/fimgfx.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tools/fimgfx.c b/tools/fimgfx.c index 360843e..17501f6 100644 --- a/tools/fimgfx.c +++ b/tools/fimgfx.c @@ -48,7 +48,7 @@ for (n=0, fx=fx_list; fx->name; fx++, n++) { fprintf(stderr, "-> %3d %s\n", n, fx->name); #endif if (!strcmp(fx->name, txt)) { - return n; + return fx->id; } } return -1; /* NOT FOUND */ @@ -83,9 +83,9 @@ static void help(int lvl) { Fx *fx; -puts("------ fimg special effects ------"); +printf("-- fimg special effects %s %s --", __DATE__, __TIME__); puts("usage:"); -puts("\tfimgfix [options] source.fimg resultat.fimg"); +puts("\tfimgfx [options] source.fimg resultat.fimg"); puts("options:"); puts("\t-k N.N\tset the floating value"); @@ -97,6 +97,7 @@ for (fx=fx_list; fx->name; fx++) { printf("%s ", fx->name); } puts(""); +fimg_print_version(1); exit(0); } /* --------------------------------------------------------------------- */ @@ -148,7 +149,8 @@ switch (act) { return -3; default: - fprintf(stderr, "*** %s : %d is bad action\n", __func__, act); + fprintf(stderr, "%s %s : %d is bad action\n", + __FILE__, __func__, act); break; }