Changeset 1735
- Timestamp:
- Sep 8, 2004, 1:58:36 PM (22 years ago)
- Location:
- trunk/psLib/src
- Files:
-
- 2 edited
-
sys/psTrace.c (modified) (2 diffs)
-
sysUtils/psTrace.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/sys/psTrace.c
r1733 r1735 9 9 * @author George Gusciora, MHPCC 10 10 * 11 * @version $Revision: 1.2 4$ $Name: not supported by cvs2svn $12 * @date $Date: 2004-09-08 2 2:10:06 $11 * @version $Revision: 1.25 $ $Name: not supported by cvs2svn $ 12 * @date $Date: 2004-09-08 23:58:36 $ 13 13 * 14 14 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 230 230 int level) // desired trace level 231 231 { 232 char *compName = NULL; 233 232 234 // If the root component tree does not exist, then initialize it. 233 235 if (cRoot == NULL) { 234 236 initTrace(); 235 237 } 238 239 if (comp[0] != '.') { 240 compName = (char *) psAlloc(2 + strlen(comp)); 241 compName[0] = '.'; 242 compName = strcat(compName, comp); 243 } else { 244 compName = (char *) comp; 245 } 246 236 247 // Add the new component to the component tree. 237 if ( !componentAdd(comp, level) ) { 238 psErrorMsg(PS_ERRORNAME_DOMAIN "psTraceSetLevel", PS_ERR_UNKNOWN, false, 239 PS_ERRORTEXT_psTrace_FAILED_TO_ADD_COMPONENT,level,comp); 248 if ( !componentAdd(compName, level) ) { 249 psErrorMsg(PS_ERRORNAME_DOMAIN "psTraceSetLevel", 250 PS_ERR_UNKNOWN, 251 false, 252 PS_ERRORTEXT_psTrace_FAILED_TO_ADD_COMPONENT, 253 level, 254 compName); 255 if (comp[0] != '.') { 256 psFree(compName); 257 } 240 258 return false; 259 } 260 261 if (comp[0] != '.') { 262 psFree(compName); 241 263 } 242 264 return true; -
trunk/psLib/src/sysUtils/psTrace.c
r1733 r1735 9 9 * @author George Gusciora, MHPCC 10 10 * 11 * @version $Revision: 1.2 4$ $Name: not supported by cvs2svn $12 * @date $Date: 2004-09-08 2 2:10:06 $11 * @version $Revision: 1.25 $ $Name: not supported by cvs2svn $ 12 * @date $Date: 2004-09-08 23:58:36 $ 13 13 * 14 14 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 230 230 int level) // desired trace level 231 231 { 232 char *compName = NULL; 233 232 234 // If the root component tree does not exist, then initialize it. 233 235 if (cRoot == NULL) { 234 236 initTrace(); 235 237 } 238 239 if (comp[0] != '.') { 240 compName = (char *) psAlloc(2 + strlen(comp)); 241 compName[0] = '.'; 242 compName = strcat(compName, comp); 243 } else { 244 compName = (char *) comp; 245 } 246 236 247 // Add the new component to the component tree. 237 if ( !componentAdd(comp, level) ) { 238 psErrorMsg(PS_ERRORNAME_DOMAIN "psTraceSetLevel", PS_ERR_UNKNOWN, false, 239 PS_ERRORTEXT_psTrace_FAILED_TO_ADD_COMPONENT,level,comp); 248 if ( !componentAdd(compName, level) ) { 249 psErrorMsg(PS_ERRORNAME_DOMAIN "psTraceSetLevel", 250 PS_ERR_UNKNOWN, 251 false, 252 PS_ERRORTEXT_psTrace_FAILED_TO_ADD_COMPONENT, 253 level, 254 compName); 255 if (comp[0] != '.') { 256 psFree(compName); 257 } 240 258 return false; 259 } 260 261 if (comp[0] != '.') { 262 psFree(compName); 241 263 } 242 264 return true;
Note:
See TracChangeset
for help on using the changeset viewer.
