SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
21
lang/bootgcc/patches/patch-libiberty_cp-demangle_c
Normal file
21
lang/bootgcc/patches/patch-libiberty_cp-demangle_c
Normal file
|
@ -0,0 +1,21 @@
|
|||
Index: libiberty/cp-demangle.c
|
||||
--- libiberty/cp-demangle.c.orig
|
||||
+++ libiberty/cp-demangle.c
|
||||
@@ -4255,7 +4255,7 @@ static inline void
|
||||
d_append_num (struct d_print_info *dpi, int l)
|
||||
{
|
||||
char buf[25];
|
||||
- sprintf (buf,"%d", l);
|
||||
+ snprintf (buf, 25, "%d", l);
|
||||
d_append_string (dpi, buf);
|
||||
}
|
||||
|
||||
@@ -6383,7 +6383,7 @@ __cxa_demangle (const char *mangled_name, char *output
|
||||
{
|
||||
if (strlen (demangled) < *length)
|
||||
{
|
||||
- strcpy (output_buffer, demangled);
|
||||
+ strlcpy (output_buffer, demangled, *length);
|
||||
free (demangled);
|
||||
demangled = output_buffer;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue