sysctl-util: use read_full_virtual_file() for reading sysctls
authorLennart Poettering <lennart@poettering.net>
Fri, 5 Mar 2021 19:34:16 +0000 (20:34 +0100)
committerLennart Poettering <lennart@poettering.net>
Fri, 5 Mar 2021 19:38:51 +0000 (20:38 +0100)
commit4b30f2e135ee84041bb597edca7225858f4ef4fb
tree1c238f9d9b25002c81fb46e9bf87d3bf27965569
parent63dc82d378e1cfda8f560e8da9aa2df549c2b026
sysctl-util: use read_full_virtual_file() for reading sysctls

Given these files are part of procfs, let's use the correct API calls
for reading them.

This changes one occasion of read_one_line_file() to
read_full_virtual_file(), which superficially is a different thing, but
shouldn't actually be a difference, since sysctls can't be longer than
4K anyway, and the piecemeal logic behind read_one_line_file() cannot
work with the special semantics of procfs anyway.
src/shared/sysctl-util.c