From: Jim S. <jse...@us...> - 2002-05-08 00:50:24
|
Update of /cvsroot/gaim/gaim/src/protocols/jabber In directory usw-pr-cvs1:/tmp/cvs-serv19216/src/protocols/jabber Modified Files: jabber.c Log Message: Whacked buffer overflow bug in gjab_recv(). Thanks to rwscott. Index: jabber.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/jabber/jabber.c,v retrieving revision 1.47 retrieving revision 1.48 diff -u -d -r1.47 -r1.48 --- jabber.c 7 May 2002 00:51:15 -0000 1.47 +++ jabber.c 8 May 2002 00:50:22 -0000 1.48 @@ -401,7 +401,7 @@ if (!gjc || gjc->state == JCONN_STATE_OFF) return; - if ((len = read(gjc->fd, buf, sizeof(buf))) > 0) { + if ((len = read(gjc->fd, buf, sizeof(buf) - 1)) > 0) { struct jabber_data *jd = GJ_GC(gjc)->proto_data; buf[len] = '\0'; debug_printf("input (len %d): %s\n", len, buf); |