IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 17207


Ignore:
Timestamp:
Mar 28, 2008, 3:39:06 PM (18 years ago)
Author:
eugene
Message:

drop unused config values; require pre-existing db directory

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/relastro/src/ConfigInit.c

    r17126 r17207  
    66  char CatdirPhotcodeFile[256];
    77  char MasterPhotcodeFile[256];
     8  struct stat filestat;
     9  int status;
    810
    911  /*** load configuration info ***/
     
    2931  GetConfig (config, "PM_TOOFEW",              "%d",  0, &PM_TOOFEW);
    3032  GetConfig (config, "POS_TOOFEW",             "%d",  0, &POS_TOOFEW);
    31   GetConfig (config, "IMAGE_TOOFEW",           "%d",  0, &IMAGE_TOOFEW);
    32   GetConfig (config, "IMAGE_GOOD_FRACTION",    "%lf", 0, &IMAGE_GOOD_FRACTION);
    3333
    3434  GetConfig (config, "GSCFILE",                "%s",  0, GSCFILE);
     
    4747  }
    4848
    49   // GetConfig (config, "ZERO_PT",                "%lf", 0, &ZERO_POINT);
    50   // GetConfig (config, "RELPHOT_GRID_X",         "%d",  0, &RELPHOT_GRID_X);
    51   // GetConfig (config, "RELPHOT_GRID_Y",         "%d",  0, &RELPHOT_GRID_Y);
    52   // GetConfig (config, "RELPHOT_GRID_BINNING",   "%d",  0, &RELPHOT_GRID_BINNING);
    53   // GetConfig (config, "CAMERA_CONFIG",          "%s",  0, CameraConfig);
    54 
    5549  if (*CATMODE == 0) strcpy (CATMODE, "RAW");
    5650  if (*CATFORMAT == 0) strcpy (CATFORMAT, "ELIXIR");
    5751
    58   /* XXX this does not yet write out the master photcode table */
     52  // check for existence of CATDIR
     53  status = stat (CATDIR, &filestat);
     54  if (status == -1) {
     55    fprintf (stderr, "directory %s does not exist, giving up\n", CATDIR);
     56    exit (1);
     57  }
     58
     59  /* update master photcode table if not defined */
    5960  sprintf (CatdirPhotcodeFile, "%s/Photcodes.dat", CATDIR);
    6061  if (!LoadPhotcodes (CatdirPhotcodeFile, MasterPhotcodeFile)) {
Note: See TracChangeset for help on using the changeset viewer.