diff options
Diffstat (limited to 'generic/tclIORChan.c')
| -rw-r--r-- | generic/tclIORChan.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/generic/tclIORChan.c b/generic/tclIORChan.c index e342126..41e9e88 100644 --- a/generic/tclIORChan.c +++ b/generic/tclIORChan.c @@ -587,6 +587,9 @@ TclChanCreateObjCmd( rcId = NextHandle(); rcPtr = NewReflectedChannel(interp, cmdObj, mode, rcId); + if (!rcPtr) { + return TCL_ERROR; + } /* * Invoke 'initialize' and validate that the handler is present and ok. @@ -1402,7 +1405,7 @@ ReflectInput( if (toRead < bytec) { SetChannelErrorStr(rcPtr->chan, msg_read_toomuch); - goto invalid; + goto invalid; } *errorCodePtr = EOK; @@ -3344,7 +3347,7 @@ ForwardProc( char *buf = (char *)ckalloc(200); snprintf(buf, 200, - "{Expected list with even number of elements, got %d %s instead}", + "{Expected list with even number of elements, got %" TCL_SIZE_MODIFIER "d %s instead}", listc, (listc == 1 ? "element" : "elements")); ForwardSetDynamicError(paramPtr, buf); |
