Sorry.
Should have been:

After:  (line 2280)
        while ( listCountRead < listCountWrite ) 
        { 
Put:
                // Check if listedAddr could have an overflow 
                // The current field can spawn 8 fields at maximum 
                if( listCountWrite+8 >= listCountRead+size ) 
                { 
                        size_t oldsize = size; 
                        size<<1;   // Double the size of the map the map.
                                   // Since this will only be used in context
                                   // of listedAddr (and will be changed back)
                                   // this should not cause flaws in the other
                                   // parts of the code.

                        FILE *MapLog = 
globalContainer->logFileManager->getFile("Map"); 
                        fprintf(MapLog, "changed size to %d, Gradient Type: 
%d\n", size, gradientType); 

                        Tint *listedAddrTmp = new Tint[size];
                        for(int i=0; i < listCountWrite-listCountRead; i++) 
                                *listedAddrTmp[i] = 
listedAddr[(i+listCountRead)&oldsize]; 
                        updateGlobalGradientVersionSimple<Tint>(gradient, 
listedAddrTmp, listCountWrite-listCountRead, gradientType); 
                        size>>1;   // change back to previous size
                        return;
                } 


-- 
Kai Antweiler



_______________________________________________
glob2-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/glob2-devel

Reply via email to