From: simon Date: Sun, 14 Jul 2013 10:45:54 +0000 (+0000) Subject: Tighten up a lot of casts from unsigned to int which are read by one X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/commitdiff_plain/b165006759a81e8ecc4e86e0540fd69343ea46e9?hp=b165006759a81e8ecc4e86e0540fd69343ea46e9 Tighten up a lot of casts from unsigned to int which are read by one of the GET_32BIT macros and then used as length fields. Missing bounds checks against zero have been added, and also I've introduced a helper function toint() which casts from unsigned to int in such a way as to avoid C undefined behaviour, since I'm not sure I trust compilers any more to do the obviously sensible thing. git-svn-id: svn://svn.tartarus.org/sgt/putty@9918 cda61777-01e9-0310-a592-d414129be87e ---