From 97a3b2d04dbfd9c56f1181b5f45864bcb1472099 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Thu, 26 Mar 2009 16:33:25 +0100 Subject: remove pointless check this function is always called with found != 0 nowadays --- src/corelib/kernel/qtranslator.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/corelib/kernel/qtranslator.cpp b/src/corelib/kernel/qtranslator.cpp index f97a319..1eca817 100644 --- a/src/corelib/kernel/qtranslator.cpp +++ b/src/corelib/kernel/qtranslator.cpp @@ -95,8 +95,7 @@ static bool match(const uchar* found, const char* target, uint len) // (normalize it to be without the zero-terminating symbol) if (len > 0 && found[len-1] == '\0') --len; - // 0 means anything, "" means empty - return !found || (qstrncmp((const char *)found, target, len) == 0 && target[len] == '\0'); + return (qstrncmp((const char *)found, target, len) == 0 && target[len] == '\0'); } static uint elfHash(const char *name) -- cgit v0.12