diff options
author | Miguel Sofer <miguel.sofer@gmail.com> | 2006-10-22 00:13:28 (GMT) |
---|---|---|
committer | Miguel Sofer <miguel.sofer@gmail.com> | 2006-10-22 00:13:28 (GMT) |
commit | 26d407419e1440003de4682f5d60c8c45ec76260 (patch) | |
tree | b77bf364d44aa23e0ee2899d93b8e0118c972b1a /generic/tcl.h | |
parent | 90490cce920eb45b480cff3690ae01e5e2241794 (diff) | |
download | tcl-26d407419e1440003de4682f5d60c8c45ec76260.zip tcl-26d407419e1440003de4682f5d60c8c45ec76260.tar.gz tcl-26d407419e1440003de4682f5d60c8c45ec76260.tar.bz2 |
* generic/tcl.h:
* generic/tclHash.c: Tcl_FindHashEntry() now calls
Tcl_CreateHashEntry() with a newPtr set to NULL: this would have
caused a segfault previously and eliminates duplicated code. A
macro has been added to tcl.h (only used when
TCL_PRESERVE_BINARY_COMPATABALITY is not set - ie, not by default).
Diffstat (limited to 'generic/tcl.h')
-rw-r--r-- | generic/tcl.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/generic/tcl.h b/generic/tcl.h index 3501c96..922da8f 100644 --- a/generic/tcl.h +++ b/generic/tcl.h @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tcl.h,v 1.219 2006/10/20 15:16:47 dkf Exp $ + * RCS: @(#) $Id: tcl.h,v 1.220 2006/10/22 00:13:29 msofer Exp $ */ #ifndef _TCL @@ -1394,7 +1394,9 @@ typedef struct Tcl_HashSearch { * Macro to use new extended version of Tcl_InitHashTable. */ # define Tcl_InitHashTable(tablePtr, keyType) \ - Tcl_InitHashTableEx(tablePtr, keyType, NULL) + Tcl_InitHashTableEx((tablePtr), (keyType), NULL) +# define Tcl_FindHashEntry(tablePtr, key) \ + Tcl_CreateHashEntry((tablePtr), (key), NULL) #endif /* TCL_PRESERVE_BINARY_COMPATABILITY */ /* |