IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 27852


Ignore:
Timestamp:
May 4, 2010, 10:00:17 AM (16 years ago)
Author:
bills
Message:

Fix error in byid diff

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/PS-IPP-PStamp/lib/PS/IPP/PStamp/Job.pm

    r27802 r27852  
    457457    my $command = "$difftool -dbname $imagedb";
    458458   
     459    my $listrun = 0;
    459460    if ($byid) {
    460         $command .= " -listrun -diff_id $id";
     461        if ($skycell_id) {
     462            $command .= " -diffskyfile -diff_id $id -skycell_id $skycell_id";
     463        } else {
     464            $command .= " -listrun -diff_id $id";
     465            $listrun = 1;
     466        }
    461467    } else {
    462468        $command .= " -diffskyfile -diff_skyfile_id $id";
    463469    }
    464     $command .= " -skycell_id $skycell_id" if $skycell_id;
    465470
    466471    my $output = runToolAndParse($command, $verbose);
    467472
    468     my $n = @$output;
    469     if (!$byid && ($n > 1)) {
     473    my $n = $output ? scalar @$output : 0;
     474    if (!$listrun && ($n > 1)) {
    470475        die ("difftool returned an unexpected number of diffskyfiles: $n");
    471476    } elsif ($n == 0) {
     
    474479
    475480    my $images;
    476     if ($byid) {
     481    if ($listrun) {
    477482        $images = selectComponents($ipprc, $imagedb, 'byid', 'diff', $rowList, $output, $verbose);
    478483    } else {
Note: See TracChangeset for help on using the changeset viewer.