diff options
author | dgp <dgp@users.sourceforge.net> | 2018-04-05 15:37:40 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2018-04-05 15:37:40 (GMT) |
commit | eb8817687f0753816e8308b93b3e992414afeca4 (patch) | |
tree | 372853cc650d958a2bca125e652a970ceb0ea82b /generic/tclStringRep.h | |
parent | 0ad3b13e2663019e4ff8d3dc944fd030e33eb358 (diff) | |
download | tcl-eb8817687f0753816e8308b93b3e992414afeca4.zip tcl-eb8817687f0753816e8308b93b3e992414afeca4.tar.gz tcl-eb8817687f0753816e8308b93b3e992414afeca4.tar.bz2 |
[string cat] was failing to NUL terminate string reps.
Stopped "string" values triggering false valgrind alarms when tests make
use of [tcl::unsupported::representation].
Diffstat (limited to 'generic/tclStringRep.h')
-rw-r--r-- | generic/tclStringRep.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/generic/tclStringRep.h b/generic/tclStringRep.h index 1ef1957..fc5a713 100644 --- a/generic/tclStringRep.h +++ b/generic/tclStringRep.h @@ -86,6 +86,7 @@ typedef struct { #define GET_STRING(objPtr) \ ((String *) (objPtr)->internalRep.twoPtrValue.ptr1) #define SET_STRING(objPtr, stringPtr) \ + ((objPtr)->internalRep.twoPtrValue.ptr2 = NULL), \ ((objPtr)->internalRep.twoPtrValue.ptr1 = (void *) (stringPtr)) /* |