Blob Blame History Raw
diff -Naurp insight-13.0.50.20220502.orig/gdb/symtab.c insight-13.0.50.20220502.new/gdb/symtab.c
--- insight-13.0.50.20220502.orig/gdb/symtab.c	2022-04-29 17:41:52.000000000 +0200
+++ insight-13.0.50.20220502.new/gdb/symtab.c	2022-05-03 01:05:39.375871418 +0200
@@ -5017,9 +5017,10 @@ global_symbol_searcher::search () const
 	  /* If wrong number of spaces, fix it.  */
 	  if (fix >= 0)
 	    {
-	      char *tmp = (char *) alloca (8 + fix + strlen (opname) + 1);
+	      int tmpsize = 8 + fix + strlen (opname) + 1;
+	      char *tmp = (char *) alloca (tmpsize);
 
-	      sprintf (tmp, "operator%.*s%s", fix, " ", opname);
+	      snprintf (tmp, tmpsize, "operator%.*s%s", fix, " ", opname);
 	      symbol_name_regexp = tmp;
 	    }
 	}