mkvers: fix potential buffer overflow 57/12657/2
authorChristof Hanke <christof.hanke@rzg.mpg.de>
Tue, 18 Jul 2017 10:04:11 +0000 (12:04 +0200)
committerBenjamin Kaduk <kaduk@mit.edu>
Tue, 18 Jul 2017 18:05:32 +0000 (14:05 -0400)
commita5bedda935c8147517bcbb56858dd88288fdf9da
treef35393217bfaea93e9b1d8e4c89956025dc53ebd
parentd7211350eec18b30e9ccf30f5e95fb58162c637d
mkvers: fix potential buffer overflow

The space allocated for outputFileBuf is only 2 bytes larger than
sizeof(VERS_FILE). But we add potentially 4 extra bytes like
".txt" or ".xml". Just allocate enough space for all file suffices.

Change-Id: Ic0f97590be208deaf9c4a5c25e21056ea9d2cd6f
Reviewed-on: https://gerrit.openafs.org/12657
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/config/mkvers.c