IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 38658


Ignore:
Timestamp:
Aug 1, 2015, 4:04:39 PM (11 years ago)
Author:
eugene
Message:

do not try to write out empty lensing, lensobj, etc tables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20150625/Ohana/src/libdvo/src/dvo_catalog_split.c

    r38613 r38658  
    9292  if (OHANA_MEMCHECK) ohana_memcheck (TRUE);
    9393 
     94  if (!catalog->f) return TRUE;
     95
    9496  /* rewind file pointers and truncate (file is still open) */
    9597  if (fseeko (catalog->f, 0LL, SEEK_SET)) {
     
    10031005
    10041006  /*** Lensing Table ***/
    1005   if ((catalog[0].catflags & DVO_LOAD_LENSING) && (catalog[0].lensing != NULL)) {
     1007  if ((catalog[0].catflags & DVO_LOAD_LENSING) && catalog[0].lensing && Nlensing_disk_new) {
    10061008
    10071009    off_t first  = 0;                    // first row in memory to write
     
    10341036
    10351037  /*** Lensobj Table ***/
    1036   if ((catalog[0].catflags & DVO_LOAD_LENSOBJ) && (catalog[0].lensobj != NULL)) {
     1038  if ((catalog[0].catflags & DVO_LOAD_LENSOBJ) && catalog[0].lensobj && Nlensobj_disk_new) {
    10371039
    10381040    off_t first  = 0;                    // first row in memory to write
     
    10651067
    10661068  /*** StarPar Table ***/
    1067   if ((catalog[0].catflags & DVO_LOAD_STARPAR) && (catalog[0].starpar != NULL)) {
     1069  if ((catalog[0].catflags & DVO_LOAD_STARPAR) && catalog[0].starpar && Nstarpar_disk_new) {
    10681070
    10691071    off_t first  = 0;                    // first row in memory to write
     
    10961098
    10971099  /*** GalPhot Table ***/
    1098   if ((catalog[0].catflags & DVO_LOAD_GALPHOT) && (catalog[0].galphot != NULL)) {
     1100  if ((catalog[0].catflags & DVO_LOAD_GALPHOT) && catalog[0].galphot && Ngalphot_disk_new) {
    10991101
    11001102    off_t first  = 0;                    // first row in memory to write
Note: See TracChangeset for help on using the changeset viewer.