From ea161661142ab98568ea811ce791da538da981d1 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Fri, 14 Jan 2005 09:06:25 +0000 Subject: Update. 2005-01-14 Ulrich Drepper * posix/regcomp.c [!_LIBC] (init_dfa): Fix determining of relevant LC_* variable. Patch by Aharon Robbins . * stdlib/fmtmsg.c (internal_addseverity): Remove incorrect free call. * stdlib/tst-fmtmsg.c (main): Add another addseverity test. --- stdlib/fmtmsg.c | 5 +---- stdlib/tst-fmtmsg.c | 6 ++++++ 2 files changed, 7 insertions(+), 4 deletions(-) (limited to 'stdlib') diff --git a/stdlib/fmtmsg.c b/stdlib/fmtmsg.c index 2ab97b7d90..9e654c688e 100644 --- a/stdlib/fmtmsg.c +++ b/stdlib/fmtmsg.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1997,1999,2000,2001,2002,2003 Free Software Foundation, Inc. +/* Copyright (C) 1997,1999,2000-2003,2005 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1997. @@ -324,9 +324,6 @@ internal_addseverity (int severity, const char *string) if (runp != NULL) { - /* Release old string. */ - free ((char *) runp->string); - if (string != NULL) /* Change the string. */ runp->string = string; diff --git a/stdlib/tst-fmtmsg.c b/stdlib/tst-fmtmsg.c index d5369bda62..0b244e2bc0 100644 --- a/stdlib/tst-fmtmsg.c +++ b/stdlib/tst-fmtmsg.c @@ -48,5 +48,11 @@ main (void) != MM_OK) result = 1; + if (addseverity (MM_TEST, NULL) != MM_OK) + { + puts ("second addseverity failed"); + result = 1; + } + return result; } -- cgit v1.2.3-70-g09d2