IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 17744


Ignore:
Timestamp:
May 19, 2008, 1:19:32 PM (18 years ago)
Author:
jhoblitt
Message:

report correct exit codes from dsgetls

File:
1 edited

Legend:

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

    r17741 r17744  
    9797
    9898    psString cmdOutput = psSlurpFile(output);
    99     int exitStatus = pclose(output);
    100 
    101     if (exitStatus != 0) {
     99    int status = pclose(output);
     100
     101    if (status != 0) {
    102102        // mark the summitExp row as faulted
    103         if (!p_psDBRunQuery(config->dbh, "UPDATE summitExp SET fault = %d WHERE exp_name = '%s' AND camera = '%s' AND telescope = '%s'", exitStatus, filesetid, camera, telescope)) {
     103        if (!p_psDBRunQuery(config->dbh, "UPDATE summitExp SET fault = %d WHERE exp_name = '%s' AND camera = '%s' AND telescope = '%s'", WEXITSTATUS(status), filesetid, camera, telescope)) {
    104104            psError(PS_ERR_UNKNOWN, false, "database error");
    105105        }
    106106
    107107        psError(PS_ERR_UNKNOWN, true, "%s failed with exit status %d",
    108             FILESET_LS_CMD, exitStatus);
     108            FILESET_LS_CMD, WEXITSTATUS(status));
    109109        psFree(cmdOutput);
    110110        return false;
Note: See TracChangeset for help on using the changeset viewer.