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

List:       kde-commits
Subject:    kdelibs/khtml/html
From:       Benjamin Meyer <benjamin () csh ! rit ! edu>
Date:       2004-11-22 2:34:55
Message-ID: 20041122023455.4874817022 () office ! kde ! org
[Download RAW message or body]

CVS commit by bmeyer: 

Cache length of QCString sense .length() recalcuates the length every time


  M +2 -1      html_formimpl.cpp   1.414


--- kdelibs/khtml/html/html_formimpl.cpp  #1.413:1.414
@@ -126,5 +126,6 @@ static QCString encodeCString(const QCSt
     //QCString orig(e.data(), e.size());
 
-    for(unsigned pos = 0; pos < e.length(); pos++) {
+    unsigned len = e.length();
+    for(unsigned pos = 0; pos < len; pos++) {
         oldc = c;
         c = e[pos];


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

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