From: Andreas Ă–man Date: Tue, 21 Aug 2007 19:21:35 +0000 (+0000) Subject: fix a typo causing memory corruption (thanks valgrind) X-Git-Tag: 2.12~1467 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d440e8ff3a8f7035e05ec6befdd44393c8ab2d71;p=thirdparty%2Ftvheadend.git fix a typo causing memory corruption (thanks valgrind) --- diff --git a/htsclient.c b/htsclient.c index 22bda2360..090c13668 100644 --- a/htsclient.c +++ b/htsclient.c @@ -734,7 +734,7 @@ client_data_read(client_t *c) memcpy(buf, c->c_input_buf, i); buf[i] = 0; i++; - memmove(c->c_input_buf, c->c_input_buf + i, sizeof(c->c_input_buf) - 1); + memmove(c->c_input_buf, c->c_input_buf + i, sizeof(c->c_input_buf) - i); c->c_input_buf_ptr -= i; i = strlen(buf);