aboutsummaryrefslogtreecommitdiff
path: root/zsh-completion/_rc-status
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2024-05-31 16:22:11 -0400
committerWilliam Hubbs <w.d.hubbs@gmail.com>2024-06-03 14:50:37 -0500
commit70be1c02005b6d7a4805db57c2183fa32513ac46 (patch)
treeda8d6b0181c5675c27285311e295bfe01fc9686c /zsh-completion/_rc-status
parent3d30b6fddaf92c612deea88d2ced7114ed1fcf9c (diff)
librc: avoid using fixed-size buffers for paths
Use heap allocations instead. This avoids warnings: ``` ../src/librc/librc.c: In function ‘rc_service_mark’: ../src/librc/librc.c:817:58: warning: ‘/’ directive output may be truncated writing 1 byte into a region of size between 0 and 4095 [-Wformat-truncation=] 817 | snprintf(was, sizeof(was), "%s/%s/%s", | ^ ../src/librc/librc.c:817:25: note: ‘snprintf’ output 3 or more bytes (assuming 4098) into a destination of size 4096 817 | snprintf(was, sizeof(was), "%s/%s/%s", | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 818 | file, dir->value, base); | ~~~~~~~~~~~~~~~~~~~~~~~ ../src/librc/librc.c:822:58: warning: ‘snprintf’ output may be truncated before the last format character [-Wformat-truncation=] 822 | snprintf(was, sizeof(was), "%s/%s", file, dir->value); | ^ ../src/librc/librc.c:822:25: note: ‘snprintf’ output 2 or more bytes (assuming 4097) into a destination of size 4096 822 | snprintf(was, sizeof(was), "%s/%s", file, dir->value); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ```
Diffstat (limited to 'zsh-completion/_rc-status')
0 files changed, 0 insertions, 0 deletions