]> 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)
committerGeorge Joseph <gjoseph@sangoma.com>
Tue, 25 Mar 2025 21:39:38 +0000 (15:39 -0600)
commit0b0f28468403cd34430c934c329c72b5032ba714
treeebef252fc469bf49cce1c90082056d584b7a0a44
parented12e22ad9d3e8922e22b8f408d9af5ce88fa05b
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