LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File fix-qtranslator-crash.diff of Package qt3 (Project openSUSE:Factory)

--- src/kernel/qtranslator.cpp
+++ src/kernel/qtranslator.cpp
@@ -1012,7 +1012,7 @@
 	char con[256];
 	for ( ;; ) {
 	    t >> len;
-	    if ( len == 0 )
+	    if ( len == 0 || t.atEnd())
 		return QTranslatorMessage();
 	    t.readRawBytes( con, len );
 	    con[len] = '\0';