summaryrefslogtreecommitdiffstats
path: root/opensuse/core/tqt3/fix-qtranslator-crash.diff
blob: 7db222e9eede20ec87333463b96f3355ef64edac (plain)
1
2
3
4
5
6
7
8
9
10
11
--- src/kernel/qtranslator.cpp
+++ src/kernel/qtranslator.cpp
@@ -1015,7 +1015,7 @@
 	char con[256];
 	for ( ;; ) {
 	    t >> len;
-	    if ( len == 0 )
+	    if ( len == 0 || t.atEnd())
 		return TQTranslatorMessage();
 	    t.readRawBytes( con, len );
 	    con[len] = '\0';