From 0eb2e1f38f1683a4bab5f5cb60dd411a1e6f3aa2 Mon Sep 17 00:00:00 2001 From: Jesus Fernandez Date: Tue, 26 Sep 2017 14:09:14 +0200 Subject: [PATCH] Remove pointer check The win pointer is valid because it is ensured before the check. It cannot be null. Coverity-Id: 21652 Change-Id: Iec8c1710d33a4eeb3820cd70bd94bd5b02fa0b41 Reviewed-by: Edward Welbourne --- src/widgets/kernel/qwidget.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp index 4794a26804..0aa5f57e98 100644 --- a/src/widgets/kernel/qwidget.cpp +++ b/src/widgets/kernel/qwidget.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 The Qt Company Ltd. +** Copyright (C) 2017 The Qt Company Ltd. ** Copyright (C) 2016 Intel Corporation. ** Contact: https://www.qt.io/licensing/ ** @@ -1502,7 +1502,7 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO QBackingStore *store = q->backingStore(); if (!store) { - if (win && q->windowType() != Qt::Desktop) { + if (q->windowType() != Qt::Desktop) { if (q->isTopLevel()) q->setBackingStore(new QBackingStore(win)); } else {