From 8ca89f014178e1b46c0b51f94efc620b19756a1e Mon Sep 17 00:00:00 2001 From: David Maciejak Date: Tue, 28 Feb 2023 21:26:01 +0800 Subject: [PATCH] Coverity: fix RContextAttributes uninitialized variable --- src/screen.c | 2 +- util/wmiv.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/screen.c b/src/screen.c index 5f248107..6a7358fa 100644 --- a/src/screen.c +++ b/src/screen.c @@ -617,7 +617,7 @@ WScreen *wScreenInit(int screen_number) { WScreen *scr; XIconSize icon_size[1]; - RContextAttributes rattr; + RContextAttributes rattr = {}; long event_mask; XErrorHandler oldHandler; int i; diff --git a/util/wmiv.c b/util/wmiv.c index cb64ec7e..7717baf3 100755 --- a/util/wmiv.c +++ b/util/wmiv.c @@ -680,7 +680,7 @@ link_t *connect_dir(char *dirpath, linked_list_t *li) int main(int argc, char **argv) { int option = -1; - RContextAttributes attr; + RContextAttributes attr = {}; XEvent e; KeySym keysym; char *reading_filename = "";