Changeset 6165 for trunk/ippTools/src/p2searchPendingFrames.c
- Timestamp:
- Jan 21, 2006, 9:27:31 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/p2searchPendingFrames.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/p2searchPendingFrames.c
r6162 r6165 124 124 return imfiles; 125 125 } 126 127 psArray *p2searchPendingExp(p2Config *config) 128 { 129 PS_ASSERT_PTR_NON_NULL(config, NULL); 130 131 psMetadata *where = psMetadataAlloc(); 132 if (config->camera_name != NULL) { 133 if (!psMetadataAddStr(where, PS_LIST_TAIL, "camera", 0, "==", 134 config->camera_name)) { 135 psError(PS_ERR_UNKNOWN, false, "failed to add item camera"); 136 psFree(where); 137 return NULL; 138 } 139 } 140 if (config->filter != NULL) { 141 psMetadataAddStr(where, PS_LIST_TAIL, "filter", 0, "==", 142 config->filter); 143 } 144 if (config->exp_id != NULL) { 145 psMetadataAddStr(where, PS_LIST_TAIL, "exp_id", 0, "==", 146 config->exp_id); 147 } 148 if (config->class != NULL) { 149 psMetadataAddStr(where, PS_LIST_TAIL, "class", 0, "==", 150 config->class); 151 } 152 if (config->class_id != NULL) { 153 psMetadataAddStr(where, PS_LIST_TAIL, "class_id", 0, "==", 154 config->class_id); 155 } 156 157 if (where->list->n < 1) { 158 psFree(where); 159 where = NULL; 160 } 161 162 psArray *exps = p2PendingExpSelectRowObjects(config->database, where, 163 MAX_ROWS); 164 psFree(where); 165 if (!exps) { 166 psError(PS_ERR_UNKNOWN, false, "no p2PendingExp rows found"); 167 168 return NULL; 169 } 170 171 return exps; 172 }
Note:
See TracChangeset
for help on using the changeset viewer.
