summaryrefslogtreecommitdiff
path: root/library
Side-by-side diff
Diffstat (limited to 'library') (more/less context) (ignore whitespace changes)
-rw-r--r--library/config.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/library/config.cpp b/library/config.cpp
index 8b60f60..0bfb476 100644
--- a/library/config.cpp
+++ b/library/config.cpp
@@ -521,15 +521,17 @@ void Config::read()
// hack to avoid problems if big files are passed to test
// if they are valid configs ( like passing a mp3 ... )
// I just hope that there are no conf files > 100000 byte
// not the best solution, find something else later
- if ( f.size() > 100000 ) {
+ if ( f.getch()!='[' ||f.size() > 100000 ) {
+ git = groups.end();
return;
}
+ f.ungetch('[');
QTextStream s( &f );
#if QT_VERSION <= 230 && defined(QT_NO_CODECS)
// The below should work, but doesn't in Qt 2.3.0
s.setCodec( QTextCodec::codecForMib( 106 ) );