From a8be3520ecd9188751dd436e40be9385c14ea107 Mon Sep 17 00:00:00 2001 From: Ivailo Monev Date: Tue, 24 May 2022 16:24:51 +0300 Subject: [PATCH] kinit: correct warnings scope in kdeinit_xio_errhandler() Signed-off-by: Ivailo Monev --- kinit/kinit.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/kinit/kinit.cpp b/kinit/kinit.cpp index de88e342..2fe15acb 100644 --- a/kinit/kinit.cpp +++ b/kinit/kinit.cpp @@ -1339,9 +1339,8 @@ static void kdeinit_library_path() int kdeinit_xio_errhandler( Display *disp ) { // disp is 0L when KDE shuts down. We don't want those warnings then. - if ( disp ) - kWarning() << "Fatal IO error: client killed"; + kWarning() << "Fatal IO error: client killed"; if (sock_file[0]) { @@ -1358,7 +1357,7 @@ int kdeinit_xio_errhandler( Display *disp ) } if ( disp ) - kWarning() << "Sending SIGHUP to children."; + kWarning() << "Sending SIGHUP to children."; /* this should remove all children we started */ KDE_signal(SIGHUP, SIG_IGN); @@ -1367,14 +1366,14 @@ int kdeinit_xio_errhandler( Display *disp ) sleep(2); if ( disp ) - kWarning() << "Sending SIGTERM to children."; + kWarning() << "Sending SIGTERM to children."; /* and if they don't listen to us, this should work */ KDE_signal(SIGTERM, SIG_IGN); kill(0, SIGTERM); if ( disp ) - kWarning() << "Exit."; + kWarning() << "Exit."; exit( 0 ); return 0;