Changeset 6978 for trunk/ippTools/src/pztoolConfig.c
- Timestamp:
- Apr 24, 2006, 5:35:03 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/pztoolConfig.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/pztoolConfig.c
r6670 r6978 1 #ifdef HAVE_CONFIG_H 2 #include <config.h> 3 #endif 4 1 5 #include <pmConfig.h> 2 6 3 7 #include "pxtools.h" 4 8 5 bool pzsearchConfig(pxConfig *config, int argc, char **argv) { 6 PS_ASSERT_PTR_NON_NULL(config, false); 9 pxConfig *pzsearchConfig(pxConfig *config, int argc, char **argv) { 10 if (!config) { 11 config = pxConfigAlloc(); 12 } 7 13 8 14 if (! pmConfigRead(&config->site, &config->camera, &config->recipe, &argc, argv, RECIPE)) { … … 95 101 psError(PS_ERR_UNKNOWN, false, "failed to add item exp_id"); 96 102 psFree(where); 97 return NULL;103 exit(EXIT_FAILURE); 98 104 } 99 105 } … … 102 108 psError(PS_ERR_UNKNOWN, false, "failed to add item class"); 103 109 psFree(where); 104 return NULL;110 exit(EXIT_FAILURE); 105 111 } 106 112 } … … 109 115 psError(PS_ERR_UNKNOWN, false, "failed to add item class_id"); 110 116 psFree(where); 111 return NULL;117 exit(EXIT_FAILURE); 112 118 } 113 119 } … … 123 129 config->dbh = pmConfigDB(config->site); 124 130 125 return true;131 return config; 126 132 }
Note:
See TracChangeset
for help on using the changeset viewer.
