diff options
author | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2009-11-19 21:06:26 (GMT) |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@nokia.com> | 2009-11-19 21:06:26 (GMT) |
commit | 70f482d84022da55b8cc7580d9993a339165219b (patch) | |
tree | f917476fd82e566db81513d962f48dfff9c83ec6 | |
parent | 901b0391d15ab72830fcfd73048eeff03fb9ed07 (diff) | |
download | Qt-70f482d84022da55b8cc7580d9993a339165219b.zip Qt-70f482d84022da55b8cc7580d9993a339165219b.tar.gz Qt-70f482d84022da55b8cc7580d9993a339165219b.tar.bz2 |
fix potentially wrong output codec for UTF-16 input files
querying the actual codec before the file has been read is pointless
-rw-r--r-- | tools/linguist/lupdate/cpp.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/linguist/lupdate/cpp.cpp b/tools/linguist/lupdate/cpp.cpp index 443abd0..bd7d4ec 100644 --- a/tools/linguist/lupdate/cpp.cpp +++ b/tools/linguist/lupdate/cpp.cpp @@ -2150,9 +2150,9 @@ void loadCPP(Translator &translator, const QStringList &filenames, ConversionDat QTextStream ts(&file); ts.setCodec(codec); ts.setAutoDetectUnicode(true); + parser.setInput(ts, filename); if (ts.codec()->name() == "UTF-16") translator.setCodecName("System"); - parser.setInput(ts, filename); Translator *tor = new Translator; tor->setCodecName(translator.codecName()); parser.setTranslator(tor); |