Changeset 8427 for trunk/Ohana/src/opihi/dvo/cmd.c
- Timestamp:
- Aug 20, 2006, 5:36:41 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/Ohana/src/opihi/dvo/cmd.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/opihi/dvo/cmd.c
r7917 r8427 57 57 /* lock, load, unlock catalog */ 58 58 catalog.filename = skylist[0].filename[j]; 59 switch (lock_catalog (&catalog, LCK_SOFT)) { 60 case 2: 61 unlock_catalog (&catalog); 62 case 0: 63 continue; 59 catalog.catflags = LOAD_AVES | LOAD_MEAS | LOAD_SECF; 60 61 // an error exit status here is a significant error 62 if (!dvo_catalog_open (&catalog, NULL, FALSE, "r")) { 63 fprintf (stderr, "ERROR: failure to open catalog file %s\n", catalog.filename); 64 exit (2); 64 65 } 65 catalog.catflags = LOAD_AVES | LOAD_MEAS | LOAD_SECF; 66 if (!load_catalog (&catalog, FALSE)) { 67 unlock_catalog (&catalog); 68 continue; 69 } 70 unlock_catalog (&catalog); 66 dvo_catalog_unlock (&catalog); 71 67 72 68 /* get correct mags, convert to X,Y */ … … 107 103 if (M3 != NULL) free (M3); 108 104 } 109 if (catalog.average != NULL) free (catalog.average); 110 if (catalog.secfilt != NULL) free (catalog.secfilt); 111 if (catalog.measure != NULL) free (catalog.measure); 112 catalog.average = (Average *) NULL; 113 catalog.secfilt = (SecFilt *) NULL; 114 catalog.measure = (Measure *) NULL; 105 dvo_catalog_free (&catalog); 115 106 } 116 107 SkyListFree (skylist, ((RegionName != NULL) || (RegionList != NULL))); … … 124 115 escape: 125 116 SkyListFree (skylist, ((RegionName != NULL) || (RegionList != NULL))); 126 if (catalog.average != NULL) free (catalog.average); 127 if (catalog.secfilt != NULL) free (catalog.secfilt); 128 if (catalog.measure != NULL) free (catalog.measure); 117 dvo_catalog_free (&catalog); 129 118 if (RegionName != NULL) free (RegionName); 130 119 if (RegionList != NULL) free (RegionList);
Note:
See TracChangeset
for help on using the changeset viewer.
