[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #63315] Test failures with 4.4 on OpenBSD
From: |
Paul D. Smith |
Subject: |
[bug #63315] Test failures with 4.4 on OpenBSD |
Date: |
Sat, 5 Nov 2022 12:59:39 -0400 (EDT) |
Follow-up Comment #3, bug #63315 (project make):
Thank you for the assist Brad; I have found the problem and will fix it in the
next release.
FYI:
diff --git a/src/function.c b/src/function.c
index f0ef3434..893e583d 100644
--- a/src/function.c
+++ b/src/function.c
@@ -2801,7 +2801,7 @@ define_new_function (const floc *flocp, const char
*name,
_("Invalid maximum argument count (%u) for function %s"), max,
name);
ent = xmalloc (sizeof (struct function_table_entry));
- ent->name = name;
+ ent->name = xstrdup (name);
ent->len = (unsigned char) len;
ent->minimum_args = (unsigned char) min;
ent->maximum_args = (unsigned char) max;
@@ -2812,7 +2812,11 @@ define_new_function (const floc *flocp, const char
*name,
ent->fptr.alloc_func_ptr = func;
ent = hash_insert (&function_table, ent);
- free (ent);
+ if (ent)
+ {
+ free ((void*)ent->name);
+ free (ent);
+ }
}
void
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?63315>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [bug #63315] Test failures with 4.4 on OpenBSD, Brad Smith, 2022/11/03
- [bug #63315] Test failures with 4.4 on OpenBSD, Paul D. Smith, 2022/11/04
- [bug #63315] Test failures with 4.4 on OpenBSD, Brad Smith, 2022/11/04
- Re: [bug #63315] Test failures with 4.4 on OpenBSD, Dmitry Goncharov, 2022/11/04
- [bug #63315] Test failures with 4.4 on OpenBSD,
Paul D. Smith <=
- [bug #63315] Test failures with 4.4 on OpenBSD, Brad Smith, 2022/11/05
- [bug #63315] Test failures with 4.4 on OpenBSD, Paul D. Smith, 2022/11/06
- [bug #63315] Test failures with 4.4 on OpenBSD, Paul D. Smith, 2022/11/06
- [bug #63315] Test failures with 4.4 on OpenBSD, anonymous, 2022/11/13
- [bug #63315] Test failures with 4.4 on OpenBSD, anonymous, 2022/11/13
- [bug #63315] loadapi test / user-defined function reload SEGV failures, Paul D. Smith, 2022/11/13
- [bug #63315] loadapi test / user-defined function reload SEGV failures, Paul D. Smith, 2022/11/13