From e3597fdc3d5336cd6a07d604bcd565bad821c8be Mon Sep 17 00:00:00 2001 From: Jonas Kew <34301774+Jkew01@users.noreply.github.com> Date: Thu, 27 Nov 2025 17:57:29 +1100 Subject: [PATCH] Update menus.c Correctly concatenates frame name with file extension so that the program outputs each frame to distinct files. Using strcat() instead of sprintf() --- src/menus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/menus.c b/src/menus.c index 2c375cc..9abe882 100644 --- a/src/menus.c +++ b/src/menus.c @@ -265,7 +265,7 @@ void keyFile(unsigned char key,int x,int y) { sprintf(data,"%s.%.3d",data,nfree); } else - sprintf(data,"%s.ppm",data); + strcat(data,".ppm"); if (!saveimg ) glutSetCursor(GLUT_CURSOR_WAIT); if ( key == 'B' || key == 'C' || key == 'G' ) imgTiling(sc,data,key);