IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 38424


Ignore:
Timestamp:
Jun 7, 2015, 11:41:31 AM (11 years ago)
Author:
eugene
Message:

escape messages need return chars in read_vectors

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ohana.20150429/src/opihi/cmd.data/read_vectors.c

    r38406 r38424  
    524524
    525525    int Nfields;
    526     if (!gfits_scan (&header, "TFIELDS", "%d", 1, &Nfields)) ESCAPE ("cannot find TFIELDS in header");
     526    if (!gfits_scan (&header, "TFIELDS", "%d", 1, &Nfields)) ESCAPE ("cannot find TFIELDS in header\n");
    527527    for (i = 0; i < Nfields; i++) {
    528528      gfits_byteswap_varlength_column (&table, i+1);
    529529    }
    530     if (!gfits_uncompress_table (&table, &rawtable)) ESCAPE ("failed to uncompress table");
     530    if (!gfits_uncompress_table (&table, &rawtable)) ESCAPE ("failed to uncompress table\n");
    531531    dump_raw_table (&rawtable, "rd raw");
    532532
     
    546546    Nval = 0;
    547547    if (Binary) {
    548       if (!gfits_get_bintable_column_type (outheader, argv[i], type, &Nval)) ESCAPE ("requested field not found");
    549       if (!gfits_get_bintable_column_raw (outheader, outtable, argv[i], &data, IsCompressed)) ESCAPE ("error reading data from specified field");
     548      if (!gfits_get_bintable_column_type (outheader, argv[i], type, &Nval)) ESCAPE ("requested field not found\n");
     549      if (!gfits_get_bintable_column_raw (outheader, outtable, argv[i], &data, IsCompressed)) ESCAPE ("error reading data from specified field\n");
    550550    } else {
    551       if (!gfits_get_table_column_type (outheader, argv[i], type)) ESCAPE ("requested field not found");
    552       if (!gfits_get_table_column (outheader, outtable, argv[i], &data)) ESCAPE ("error reading data from specified field");
    553     }
    554     if (Nval == 0) ESCAPE ("no data for field in table");
     551      if (!gfits_get_table_column_type (outheader, argv[i], type)) ESCAPE ("requested field not found\n");
     552      if (!gfits_get_table_column (outheader, outtable, argv[i], &data)) ESCAPE ("error reading data from specified field\n");
     553    }
     554    if (Nval == 0) ESCAPE ("no data for field in table\n");
    555555   
    556556    vecType = OPIHI_INT;
     
    589589        else
    590590          sprintf (name, "%s:%d", argv[i], j);
    591         if ((vec[j] = SelectVector (name, ANYVECTOR, TRUE)) == NULL) ESCAPE ("bad vector name");
     591        if ((vec[j] = SelectVector (name, ANYVECTOR, TRUE)) == NULL) ESCAPE ("bad vector name\n");
    592592        ResetVector (vec[j], vecType, Ny);
    593593      }
    594594
    595       if (!VectorAssignData (vec, type, data, Ny, Nval)) ESCAPE ("bad column type %s", type);
     595      if (!VectorAssignData (vec, type, data, Ny, Nval)) ESCAPE ("bad column type %s\n", type);
    596596
    597597    } else {
     
    603603        else
    604604          sprintf (name, "%s:%d", argv[i], j);
    605         if ((vec[j] = SelectVector (name, ANYVECTOR, TRUE)) == NULL) ESCAPE ("bad vector name");
     605        if ((vec[j] = SelectVector (name, ANYVECTOR, TRUE)) == NULL) ESCAPE ("bad vector name\n");
    606606        ResetVector (vec[j], vecType, Nval);
    607607      }
    608608
    609       if (!VectorAssignDataTranspose (vec, type, data, Ny, Nval)) ESCAPE ("bad column type %s", type);
     609      if (!VectorAssignDataTranspose (vec, type, data, Ny, Nval)) ESCAPE ("bad column type %s\n", type);
    610610    }
    611611    free (data);
Note: See TracChangeset for help on using the changeset viewer.