]> 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:15 +0000 (09:39 -0500)
commitb3bf41545566e37459a7b53d276f1baed3f194f9
tree59cb6cd260685f81c995e31671c2fde658b0367f
parent18cfcdcd3498b2e991198d8da08048ab8d34c85b
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