From 2db0531a57cf85cf1637c26ff4813f5e8e102902 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Tue, 6 Jun 2017 18:55:46 +0200 Subject: [PATCH] QKeySequence: remove a clause guarding an impossible condition All code paths leading up to this line unconditionally dereference the pointer, so it cannot be nullptr. Remove the check. It only confuses readers of the code and probably will trigger warnings with tomorrow's compilers. Change-Id: I31a643738e951da9c04f0091645016276b047761 Reviewed-by: Friedemann Kleint --- src/gui/kernel/qkeysequence.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/src/gui/kernel/qkeysequence.cpp b/src/gui/kernel/qkeysequence.cpp index 9905caa92a..b15ea78f7a 100644 --- a/src/gui/kernel/qkeysequence.cpp +++ b/src/gui/kernel/qkeysequence.cpp @@ -1100,7 +1100,6 @@ int QKeySequencePrivate::decodeString(const QString &str, QKeySequence::Sequence << QModifKeyName(Qt::KeypadModifier, QLatin1String("num+")); } } - if (!gmodifs) return ret; QVector modifs;