X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=blobdiff_plain;f=hbytes%2Fhook.c;fp=hbytes%2Fhook.c;h=b2d4dc4e1abc657da57497315d8999b1795a2363;hb=ceed4cf646a34245b3bc88089a2187ebf7a41f0f;hp=b49aaa1a8b9414c5de31a2193e2a23bc950e4d08;hpb=73cb29760348de6e329efdab662b8a320c92b136;p=chiark-tcl.git diff --git a/hbytes/hook.c b/hbytes/hook.c index b49aaa1..b2d4dc4 100644 --- a/hbytes/hook.c +++ b/hbytes/hook.c @@ -73,6 +73,7 @@ void cht_obj_updatestr_array_prefix(Tcl_Obj *o, const Byte *byte, int pl; pl= strlen(prefix); + assert(l < INT_MAX/2 - 1 - pl); o->length= l*2+pl; str= o->bytes= TALLOC(o->length+1);