Fix the CI failure I've caused, one more instance of the same problem
that didn't yet cause write beyound buffer, document all the functions
to prevent users from guessing and remove redundant code.
The last function also optimizes further to prevent over-allocating the
buffers to read the files.
Peter Krempa (6):
virPCIDeviceReadClass: Don't write beyond end of buffer from
virFileReadAll
virSecretLoadValue: Don't re-termiante the buffer
virNetDevIPCheckIPv6Forwarding: Don't NUL terminate buffer from
virFileReadAll
virPCIDeviceReadID: Fix use of 'virFileReadAll'
util: virfile: Document the various functions for reading from file/fd
util: virfile: Don't over-allocate buffers in saferead_lim
src/conf/virsecretobj.c | 3 -
src/util/virfile.c | 145 +++++++++++++++++++++++++++++++++++-----
src/util/virnetdevip.c | 4 --
src/util/virpci.c | 10 +--
4 files changed, 135 insertions(+), 27 deletions(-)
--
2.53.0