]> 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:06 +0000 (09:39 -0500)
commitddc6d1f796fab335ebeed0843200e3b06608782a
treea7e90320882fd76e3f957b8d30a395dc8f94ab28
parent9eadb789d50ff594c4914fe331f0666800efe5a5
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