X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=chiark-tcl.git;a=blobdiff_plain;f=base%2Fscriptinv.c;h=26d5030f762ed6fd62c5e16eaebd8c17f9403ccc;hp=5757d47b52f9ef8549a577ee29f76b7d2a050f78;hb=ceed4cf646a34245b3bc88089a2187ebf7a41f0f;hpb=73cb29760348de6e329efdab662b8a320c92b136 diff --git a/base/scriptinv.c b/base/scriptinv.c index 5757d47..26d5030 100644 --- a/base/scriptinv.c +++ b/base/scriptinv.c @@ -45,6 +45,7 @@ int cht_scriptinv_set(ScriptToInvoke *si, Tcl_Interp *ip, if (xargs) { rc= Tcl_ListObjLength(ip, xargs, &xlength); if (rc) return rc; Tcl_IncrRefCount(xargs); + assert(si->llen < INT_MAX/2 && xlength < INT_MAX/2); si->llen += xlength; }