bug 434350: filename buffer too small.
[fw/sdcc] / src / z80 / main.c
index c30d6c5736b30d1eaacbb6af3936b04870b910f6..4a7d3153e788e5cb45face4e370484dce4a96f14 100644 (file)
@@ -158,10 +158,10 @@ _gbz80_rgblink (void)
     sz = "a";
 
   /* first we need to create the <filename>.lnk file */
-  sprintf (buffer, "%s.lnk", sz);
-  if (!(lnkfile = fopen (buffer, "w")))
+  sprintf (scratchFileName, "%s.lnk", sz);
+  if (!(lnkfile = fopen (scratchFileName, "w")))
     {
-      werror (E_FILE_OPEN_ERR, buffer);
+      werror (E_FILE_OPEN_ERR, scratchFileName);
       exit (1);
     }