From: Tzafrir Cohen Date: Sun, 13 Sep 2009 21:48:02 +0000 (+0000) Subject: gcc 4.4: Remove a nop memset size 0 that annoys gcc X-Git-Tag: 1.6.1.7-rc1~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=36a844213f1c975a01f78951603548de4226fef0;p=thirdparty%2Fasterisk.git gcc 4.4: Remove a nop memset size 0 that annoys gcc This memset doesn't write beyond the end of the buffer. (tmpbuf has size of 4). Merged revisions 218184 via svnmerge from http://svn.digium.com/svn/asterisk/trunk git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@218218 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_phone.c b/channels/chan_phone.c index 6089fae283..1fcf366365 100644 --- a/channels/chan_phone.c +++ b/channels/chan_phone.c @@ -807,7 +807,6 @@ static int phone_write(struct ast_channel *ast, struct ast_frame *frame) we have to pad it to 24 bytes still. */ if (frame->datalen == 4) { if (p->silencesupression) { - (void) memset(tmpbuf + 4, 0, sizeof(tmpbuf) - 4); memcpy(tmpbuf, frame->data.ptr, 4); expected = 24; res = phone_write_buf(p, tmpbuf, expected, maxfr, 0);