pacman/src
Carlo Teubner e56c7a3f41 "pacman -Q --changelog": fix writing uninit'd mem
Previously, when printing a package changelog to stdout, we would write
chunks of data that were not necessarily nul-terminated to stdout using
a function (fputs) which requires the input string to be nul-terminated.

On my system, this would result in occasional garbage characters showing
up in the "pacman -Qc" output.

Fix this by never nul-terminating the chunk, and using the fwrite()
function which takes an explicit input size and does not require a
nul-terminated string.

Signed-off-by: Carlo Teubner <carlo@cteubner.net>
(cherry picked from commit 806ccd90ed)
2022-10-02 11:14:31 +10:00
..
common Update copyright year 2021-03-01 12:22:20 +10:00
pacman "pacman -Q --changelog": fix writing uninit'd mem 2022-10-02 11:14:31 +10:00
util add front-end provided context to callbacks 2021-05-01 12:08:14 +10:00