Changeset 12564 for trunk/psModules/src/concepts/pmConceptsWrite.c
- Timestamp:
- Mar 22, 2007, 5:09:53 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/psModules/src/concepts/pmConceptsWrite.c (modified) (13 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/concepts/pmConceptsWrite.c
r12397 r12564 57 57 while ((cItem = psListGetAndIncrement(cIter))) { 58 58 if (cItem->type != PS_DATA_STRING) { 59 ps LogMsg(__func__, PS_LOG_WARN,"psMetadataItem from list is of type %x instead of "59 psWarning("psMetadataItem from list is of type %x instead of " 60 60 "%x (PS_DATA_STRING) --- can't interpret.\n", cItem->type, PS_DATA_STRING); 61 61 psFree(cIter); … … 178 178 } 179 179 default: 180 ps LogMsg(__func__, PS_LOG_WARN,"Type of %s is not suitable for a FITS header --- not added.\n",180 psWarning("Type of %s is not suitable for a FITS header --- not added.\n", 181 181 item->name); 182 182 return false; … … 261 261 if (strcasecmp(source, "HEADER") == 0) { 262 262 if (cameraItem->type != PS_DATA_STRING) { 263 ps LogMsg(__func__, PS_LOG_WARN,"Concept %s is specified by header, but is not "263 psWarning("Concept %s is specified by header, but is not " 264 264 "of type STR --- ignored.\n", conceptItem->name); 265 265 continue; … … 286 286 psTrace("psModules.concepts", 8, "Checking %s against camera format.\n", name); 287 287 if (! compareConcepts(formatted, cameraItem)) { 288 ps LogMsg(__func__, PS_LOG_WARN,"Concept %s is specified by value in the camera "288 psWarning("Concept %s is specified by value in the camera " 289 289 "format, but the values don't match.\n", name); 290 290 } 291 291 psFree(formatted); 292 292 } else { 293 ps LogMsg(__func__, PS_LOG_WARN,"Concept source %s isn't HEADER or VALUE --- can't "293 psWarning("Concept source %s isn't HEADER or VALUE --- can't " 294 294 "write\n", nameSource); 295 295 } … … 303 303 304 304 if (! compareConcepts(formatted, cameraItem)) { 305 ps LogMsg(__func__, PS_LOG_WARN,"Concept %s is specified by value in the camera "305 psWarning("Concept %s is specified by value in the camera " 306 306 "format, but the values don't match.\n", name); 307 307 } … … 347 347 psString dependKey = psMetadataLookupStr(&mdok, defaults, dependName); // The keyword 348 348 if (!mdok || !dependKey || strlen(dependKey) == 0) { 349 ps LogMsg(__func__, PS_LOG_WARN,"Can't find %s in the DEFAULTS for %s --- ignored.\n",349 psWarning("Can't find %s in the DEFAULTS for %s --- ignored.\n", 350 350 dependName, name); 351 351 psFree(dependName); … … 354 354 psString dependValue = psMetadataLookupStr(&mdok, concepts, dependKey); // The value 355 355 if (!mdok || !dependValue || strlen(dependValue) == 0) { 356 ps LogMsg(__func__, PS_LOG_WARN,"Concept %s specified by %s isn't of type STR -- "356 psWarning("Concept %s specified by %s isn't of type STR -- " 357 357 "ignored.\n", dependKey, dependName); 358 358 psFree(dependName); … … 360 360 } 361 361 // Get the actual item of interest, and correct the name to match the concept name 362 defaultItem = psMetadataLookup(defaultItem->data.md, dependValue);363 if (!defaultItem) {364 ps LogMsg(__func__, PS_LOG_WARN,"Concept dependency name %s is not found "365 "in concept table for %s -- ignored.\n", dependValue, dependName);362 defaultItem = psMetadataLookup(defaultItem->data.md, dependValue); 363 if (!defaultItem) { 364 psWarning("Concept dependency name %s is not found " 365 "in concept table for %s -- ignored.\n", dependValue, dependName); 366 366 psFree(dependName); 367 367 continue; 368 }368 } 369 369 defaultItem = psMetadataItemCopy(defaultItem); 370 370 psFree(dependName); … … 381 381 } 382 382 if (! compareConcepts(formatted, defaultItem)) { 383 ps LogMsg(__func__, PS_LOG_WARN,"Concept %s is specified by the DEFAULTS in the camera "383 psWarning("Concept %s is specified by the DEFAULTS in the camera " 384 384 "format, but the values don't match.\n", name); 385 385 } … … 418 418 if (headerItem) { 419 419 if (headerItem->type != PS_DATA_STRING) { 420 ps LogMsg(__func__, PS_LOG_WARN,"TRANSLATION keyword for concept %s isn't of type STR ---"420 psWarning("TRANSLATION keyword for concept %s isn't of type STR ---" 421 421 " ignored.", name); 422 422 continue; … … 471 471 if (dbItem) { 472 472 if (dbItem->type != PS_DATA_METADATA) { 473 ps LogMsg(__func__, PS_LOG_WARN,"DATABASE keyword for concept %s isn't of type METADATA "473 psWarning("DATABASE keyword for concept %s isn't of type METADATA " 474 474 "--- ignored.\n", name); 475 475 continue; … … 508 508 char *dependName = psListGetAndIncrement(valuesIter); // Name for the value 509 509 if (!strlen(column) || !strlen(name)) { 510 ps LogMsg(__func__, PS_LOG_WARN,"One of the columns or value names for %s is "510 psWarning("One of the columns or value names for %s is " 511 511 " empty --- ignored.\n", name); 512 512 } else { … … 543 543 // Note that we use limit=2 in order to test if there are multiple rows returned 544 544 if (! dbResult || dbResult->n == 0) { 545 ps LogMsg(__func__, PS_LOG_WARN,"Unable to find any rows in DB for %s --- "545 psWarning("Unable to find any rows in DB for %s --- " 546 546 "ignored\n", name); 547 547 return false; 548 548 } else { 549 549 if (dbResult->n > 1) { 550 ps LogMsg(__func__, PS_LOG_WARN,"Multiple rows returned in DB lookup for %s "550 psWarning("Multiple rows returned in DB lookup for %s " 551 551 "--- ignored.\n", name); 552 552 }
Note:
See TracChangeset
for help on using the changeset viewer.
