]> git.ipfire.org Git - thirdparty/asterisk.git/commit
chan_dahdi.c: Resolve a format-truncation build warning.
authorSean Bright <sean@seanbright.com>
Fri, 19 Aug 2022 16:02:07 +0000 (12:02 -0400)
committerFriendly Automation <jenkins2@gerrit.asterisk.org>
Fri, 9 Sep 2022 14:39:12 +0000 (09:39 -0500)
commite0fe8648745a859ae208a5ddaa12af084a50c071
treee1d5905ad53bb51025386deb20b21b443eed51ab
parent8d57581c779e2121abb15b3766ca5a2b776ccab5
chan_dahdi.c: Resolve a format-truncation build warning.

With gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0:

> chan_dahdi.c:4129:18: error: ā€˜%s’ directive output may be truncated
>   writing up to 255 bytes into a region of size between 242 and 252
>   [-Werror=format-truncation=]

This removes the error-prone sizeof(...) calculations in favor of just
doubling the size of the base buffer.

Change-Id: I2d276785286730d3d5d0a921bcea2e065dbf27c5
channels/chan_dahdi.c