diff options
Diffstat (limited to 'generic/tclLink.c')
-rw-r--r-- | generic/tclLink.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tclLink.c b/generic/tclLink.c index a0212ee..0088950 100644 --- a/generic/tclLink.c +++ b/generic/tclLink.c @@ -880,7 +880,9 @@ LinkTraceProc( case TCL_LINK_BINARY: value = (char *) Tcl_GetByteArrayFromObj(valueObj, &valueLength); - if (valueLength != linkPtr->bytes) { + if (value == NULL) { + return (char *) "invalid binary value"; + } else if (valueLength != linkPtr->bytes) { return (char *) "wrong size of binary value"; } if (linkPtr->flags & LINK_ALLOC_LAST) { |