eda/IdList: Improved performance of Unserialization (for search index readback)
authorJerome St-Louis <jerome@ecere.com>
Sun, 26 Jun 2011 10:37:46 +0000 (06:37 -0400)
committerJerome St-Louis <jerome@ecere.com>
Sun, 26 Jun 2011 10:37:46 +0000 (06:37 -0400)
eda/libeda/src/idList.ec

index 68295c0..e653579 100644 (file)
@@ -258,13 +258,17 @@ public:
       channel.Unserialize(count);
       if(count != MAXDWORD)
       {
-         this = eInstance_New(_class); //IdList { };
+         IdList idList = eInstance_New(_class); //IdList { };
+         idList.count = count;
+         idList.ids = new Id[count];
          for(c = 0; c < count; c++)
          {
             Id id;
             channel.Unserialize(id);
-            Add(id);
+            //Add(id);
+            idList.ids[c] = id;
          }
+         this = idList;
       }
    }