]> git.ipfire.org Git - thirdparty/util-linux.git/commit
setterm: avoid restoring flags from uninitialized memory
authorChris Hofstaedtler <zeha@debian.org>
Tue, 31 Oct 2023 13:52:26 +0000 (14:52 +0100)
committerKarel Zak <kzak@redhat.com>
Fri, 24 Nov 2023 10:16:20 +0000 (11:16 +0100)
commit5ec7b14a72d9893d2a8d8c7f40cd45b44c9575c9
treeac88f02d220c28eedd0900d5eecc36c8d1f4133f
parent64d2300e6443c311219f187433046751a86ed18e
setterm: avoid restoring flags from uninitialized memory

Depending on the used compiler and flags, previously either F_SETFL was called
with 0 or with a random value. Never with the intended previous flags.

[kzak@redhat.com: - tiny coding style change]

Signed-off-by: Chris Hofstaedtler <zeha@debian.org>
Tested-by: Emanuele Rocca <ema@debian.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
term-utils/setterm.c