[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KOFFICE_1_3_BRANCH: koffice/lib/kotext
From:       David Faure <faure () kde ! org>
Date:       2004-01-12 9:06:50
Message-ID: 20040112090650.1C6B41420 () office ! kde ! org
[Download RAW message or body]

CVS commit by faure: 

Backport 1.126->1.128: check for null chars in autocorrect file.


  M +4 -4      koAutoFormat.cc   1.126.2.1


--- koffice/lib/kotext/koAutoFormat.cc  #1.126:1.126.2.1
@@ -348,8 +348,8 @@ void KoAutoFormat::readConfig(bool force
             {
                 QString attr = childItem.attribute( "begin" );
-                if ( !attr.isEmpty() )
+                if ( !attr.isEmpty() && attr[0] != 0 )
                     m_typographicDefaultDoubleQuotes.begin = attr[0];
                 attr = childItem.attribute( "end" );
-                if ( !attr.isEmpty() )
+                if ( !attr.isEmpty() && attr[0] != 0 )
                     m_typographicDefaultDoubleQuotes.end = attr[0];
             }
@@ -362,8 +362,8 @@ void KoAutoFormat::readConfig(bool force
             {
                 QString attr = childItem.attribute( "begin" );
-                if ( !attr.isEmpty() )
+                if ( !attr.isEmpty() && attr[0] != 0 )
                     m_typographicDefaultSimpleQuotes.begin = attr[0];
                 attr = childItem.attribute( "end" );
-                if ( !attr.isEmpty() )
+                if ( !attr.isEmpty() && attr[0] != 0 )
                     m_typographicDefaultSimpleQuotes.end = attr[0];
             }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic