IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 30403


Ignore:
Timestamp:
Jan 28, 2011, 8:32:33 AM (15 years ago)
Author:
bills
Message:

fix error when no magicRuns are pending

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-20101215/ippTools/src/magictool.c

    r30379 r30403  
    886886        return false;
    887887    }
    888     psArray *output = NULL;
    889     if (psArrayLength(magicRuns)) {
    890         output = psArrayAllocEmpty(100);
    891 
     888    if (!psArrayLength(magicRuns)) {
     889        // no magicRuns pending. Nothing to do
     890        psTrace("magictool", PS_LOG_INFO, "no rows found");
     891        psFree(magicRuns);
     892        return true;
     893    }
     894
     895    psArray *output = psArrayAllocEmpty(100);
     896    // the following is indented because I removed a conditional and I decided not to shift over
    892897        query = pxDataGet("magictool_toprocess_tree.sql");
    893898        if (!query) {
     
    989994            }
    990995        }
    991     }
     996    // the above code is indented because I removed a conditional block and I decided not to shift it over
    992997
    993998    // look for "inputs" that need to processed
Note: See TracChangeset for help on using the changeset viewer.