]> git.michaelhowe.org Git - packages/o/openafs.git/commit
Avoid format truncation warnings
authorAndrew Deason <adeason@sinenomine.net>
Tue, 7 Aug 2018 22:27:24 +0000 (17:27 -0500)
committerStephan Wiesand <stephan.wiesand@desy.de>
Sun, 3 Feb 2019 14:01:01 +0000 (09:01 -0500)
commit232bd12b070e1fbeb173e31251e65e63a0d1f959
tree17f5ad5c635fe18e3705b8f4869f0fd4547a168c
parent804fefa6b46ed75921a1560a9e6b37842eabc94a
Avoid format truncation warnings

With gcc 7.3, we start getting several warnings like the following:

vutil.c: In function ‘VWalkVolumeHeaders’:
vutil.c:860:34: error: ‘%s’ directive output may be truncated writing up to 255 bytes into a region of size 63 [-Werror=format-truncation=]
      snprintf(name, VMAXPATHLEN, "%s" OS_DIRSEP "%s", partpath, dentry->d_name);

Most or all of these truncations should be okay, but increase the size
of the relevant buffers so we can build with warning checking turned
on.

Reviewed-on: https://gerrit.openafs.org/13274
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
(cherry picked from commit 2daa413e3ec061e0653adbd1d6549f15e0659a62)

Change-Id: I61ae1ddae4b2d84147198a1dccb280d0da100a0b
Reviewed-on: https://gerrit.openafs.org/13459
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
src/aklog/klog.c
src/vol/voldefs.h
src/volser/restorevol.c