Changeset 8416
- Timestamp:
- Aug 17, 2006, 4:24:13 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/sys/psTrace.c (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/sys/psTrace.c
r8413 r8416 9 9 * @author GLG, MHPCC 10 10 * 11 * @version $Revision: 1.6 8$ $Name: not supported by cvs2svn $12 * @date $Date: 2006-08-1 7 23:05:23 $11 * @version $Revision: 1.69 $ $Name: not supported by cvs2svn $ 12 * @date $Date: 2006-08-18 02:24:13 $ 13 13 * 14 14 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 53 53 #include <string.h> 54 54 #include <stdarg.h> 55 56 #include "psAssert.h" 55 57 #include "psMemory.h" 56 58 #include "psTrace.h" … … 77 79 static p_psComponent* componentAlloc(const char *name, int level) 78 80 { 81 assert(name); 82 79 83 p_psComponent* comp = psAlloc(sizeof(p_psComponent)); 80 84 … … 130 134 void p_psTraceReset(p_psComponent* currentNode) 131 135 { 136 assert(currentNode); 137 132 138 psS32 i = 0; 133 139 … … 163 169 static psBool componentAdd(const char *addNodeName, psS32 level) 164 170 { 171 assert(addNodeName); 172 165 173 psS32 i = 0; // Loop index variable. 166 174 char name[strlen(addNodeName) + 1]; // buffer for writeable copy. … … 262 270 int level) // desired trace level 263 271 { 272 PS_ASSERT_PTR_NON_NULL(comp, 0); 273 264 274 char *compName = NULL; 265 275 int prevLevel = -1; … … 322 332 static psS32 doGetTraceLevel(const char *aname) 323 333 { 334 assert(aname); 324 335 char name[strlen(aname) + 1]; // need a writeable copy: for strsep() 325 336 char *pname = name; … … 393 404 int psTraceGetLevel(const char *name) 394 405 { 406 PS_ASSERT_PTR_NON_NULL(name, 0); 407 395 408 psS32 traceLevel; 396 409 … … 452 465 psS32 defLevel) 453 466 { 467 assert(comp); 468 454 469 char line[1024]; 455 470 psS32 i = 0; … … 644 659 ) 645 660 { 661 PS_ASSERT_PTR_NON_NULL(file, ); 662 PS_ASSERT_PTR_NON_NULL(func, ); 663 PS_ASSERT_PTR_NON_NULL(facil, ); 664 PS_ASSERT_PTR_NON_NULL(format, ); 665 646 666 // XXX file & lineo are currently unused 647 667 va_list ap;
Note:
See TracChangeset
for help on using the changeset viewer.
