http://rdesktop.cvs.sourceforge.net/rdesktop/rdesktop/iso.c?r1=1.19&r2=1.20&view=patch&pathrev=HEAD --- iso.c 2007/01/08 04:47:05 1.19 +++ iso.c 2008/02/14 11:45:13 1.20 @@ -98,6 +98,11 @@ next_be(s, length); } } + if (length < 4) + { + error("Bad packet header\n"); + return NULL; + } s = tcp_recv(s, length - 4); if (s == NULL) return NULL;