IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 15155


Ignore:
Timestamp:
Oct 1, 2007, 12:03:51 PM (19 years ago)
Author:
jhoblitt
Message:

fix index accounting in pzArrayZip()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/src/pztool.c

    r15153 r15155  
    640640    for (counter = 0, i = 0;
    641641            (counter < setSize) && (i < psArrayLength(arraySet));
    642             counter++, ++i, i = i % psArrayLength(arraySet)) {
     642            counter++, ++i, i = i % psArrayLength(arraySet), i % psArrayLength(arraySet) ? : ++index) {
    643643
    644644        psArray *array = arraySet->data[i];
    645645        // make sure that this array has not run out of elements
    646         if (index > (psArrayLength(arraySet) - 1)) {
     646        if (!(index < psArrayLength(array))) {
    647647            continue;
    648648        }
Note: See TracChangeset for help on using the changeset viewer.