diff options
author | dgp <dgp@users.sourceforge.net> | 2007-03-20 21:20:10 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2007-03-20 21:20:10 (GMT) |
commit | e09c7776b3ee325bd972de72a641f9342f6c379a (patch) | |
tree | 6c22d75c83c3ca9a0d6dbf10f9f8e95a41f3870e /generic/tclLink.c | |
parent | 1e14587ab8671097dbf480b432c3088434d59bef (diff) | |
download | tcl-e09c7776b3ee325bd972de72a641f9342f6c379a.zip tcl-e09c7776b3ee325bd972de72a641f9342f6c379a.tar.gz tcl-e09c7776b3ee325bd972de72a641f9342f6c379a.tar.bz2 |
* generic/tclEnv.c: Some more ckalloc -> ckrealloc replacements.
* generic/tclLink.c:
Diffstat (limited to 'generic/tclLink.c')
-rw-r--r-- | generic/tclLink.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/generic/tclLink.c b/generic/tclLink.c index fec4fdb..bdfa4db 100644 --- a/generic/tclLink.c +++ b/generic/tclLink.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclLink.c,v 1.19 2007/03/03 10:04:42 dkf Exp $ + * RCS: @(#) $Id: tclLink.c,v 1.20 2007/03/20 21:20:12 dgp Exp $ */ #include "tclInt.h" @@ -518,10 +518,8 @@ LinkTraceProc( value = Tcl_GetStringFromObj(valueObj, &valueLength); valueLength++; pp = (char **) linkPtr->addr; - if (*pp != NULL) { - ckfree(*pp); - } - *pp = (char *) ckalloc((unsigned) valueLength); + + *pp = ckrealloc(*pp, valueLength); memcpy(*pp, value, (unsigned) valueLength); break; |