Changeset 41549 for trunk/ippTools/src/chiptool.c
- Timestamp:
- Apr 9, 2021, 4:44:03 PM (5 years ago)
- File:
-
- 1 edited
-
trunk/ippTools/src/chiptool.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/chiptool.c
r40534 r41549 489 489 PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false); 490 490 PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false); 491 PXOPT_LOOKUP_BOOL(all, config->args, "-all", false); 491 492 492 493 psMetadata *where = psMetadataAlloc(); … … 502 503 } 503 504 504 if ( where &&psListLength(where->list)) {505 if (psListLength(where->list)) { 505 506 psString whereClause = psDBGenerateWhereConditionSQL(where, NULL); 506 507 psStringAppend(&query, " AND %s", whereClause); 507 508 psFree(whereClause); 509 } else { 510 if (!all) { 511 psError(PXTOOLS_ERR_SYS, false, "unrestricted query not allowed (try -all)"); 512 return false; 513 } 508 514 } 509 515 psFree(where); … … 1269 1275 PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false); 1270 1276 PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false); 1277 PXOPT_LOOKUP_BOOL(all, config->args, "-all", false); 1271 1278 1272 1279 psMetadata *where = psMetadataAlloc(); … … 1283 1290 psStringAppend(&query, " AND %s", whereClause); 1284 1291 psFree(whereClause); 1292 } else { 1293 if (!all) { 1294 psError(PXTOOLS_ERR_SYS, false, "unrestricted query not allowed (try -all"); 1295 return false; 1296 } 1285 1297 } 1286 1298 psFree(where); … … 1351 1363 psStringAppend(&query, " AND %s", whereClause); 1352 1364 psFree(whereClause); 1365 } else { 1366 if (!all) { 1367 psError(PXTOOLS_ERR_SYS, false, "unrestricted query not allowed (try -all)"); 1368 return false; 1369 } 1353 1370 } 1354 1371 psFree(where);
Note:
See TracChangeset
for help on using the changeset viewer.
