]> git.ipfire.org Git - thirdparty/collectd.git/commit
snmp_agent plugin: Fix strncat() truncation warning. 3564/head
authorFlorian Forster <octo@google.com>
Thu, 3 Sep 2020 07:11:07 +0000 (09:11 +0200)
committerFlorian Forster <octo@google.com>
Thu, 3 Sep 2020 07:11:07 +0000 (09:11 +0200)
commit7caa07f622ac01cf09dd6900449e8ebbe4e2f329
treee81add93a859377eceb6b8e9905495b9ac4efde5
parent70296d5aac75111ebc7a334fa88eae4701a5343c
snmp_agent plugin: Fix strncat() truncation warning.

Fixes:

```
src/snmp_agent.c:965:9: error: â€˜strncat’ output may be truncated copying between 0 and 127 bytes from a string of length 127 [-Werror=stringop-truncation]
         strncat(out, str, DATA_MAX_NAME_LEN - strlen(out) - 1);
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
```
src/snmp_agent.c