From 9ba63d1460db41c219b638212b42476164fcfdff Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 24 Jul 2018 13:08:25 +0200 Subject: Update code style, fix compiler warnings - Use nullptr instead of NULL for better warnings in case of mistakes - Get rid of VLAs which are not in C++11 actually - Fix implicit signed <-> unsigned mismatches by adding checks and casts --- src/server/util/platform/screensaver.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/server/util/platform/screensaver.cpp') diff --git a/src/server/util/platform/screensaver.cpp b/src/server/util/platform/screensaver.cpp index efffba9..cdd6ee1 100644 --- a/src/server/util/platform/screensaver.cpp +++ b/src/server/util/platform/screensaver.cpp @@ -14,17 +14,17 @@ namespace { - Display *display = NULL; + Display *display = nullptr; bool extensionSupported = false; bool dpmsSupported = false; bool init() { - if (display != NULL) { + if (display != nullptr) { return true; } display = QX11Info::display(); - if (display == NULL) { + if (display == nullptr) { return false; } #ifdef X11_Xscreensaver_FOUND -- cgit v1.2.3-55-g7522