Changeset 1643 for pjproject/trunk
- Timestamp:
- Dec 28, 2007 7:03:20 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib/src/pjlib-test/pool_perf.c
r1238 r1643 62 62 63 63 /* Symbian doesn't have malloc()/free(), so we use new/delete instead */ 64 #if defined(PJ_SYMBIAN) && PJ_SYMBIAN != 065 64 //#if defined(PJ_SYMBIAN) && PJ_SYMBIAN != 0 65 #if 0 66 66 static int pool_test_malloc_free() 67 67 { … … 69 69 70 70 for (i=0; i<COUNT; ++i) { 71 p[i] = new char[sizes[i]]; 72 if (!p[i]) { 73 PJ_LOG(3,(THIS_FILE," error: malloc failed to allocate %d bytes", 74 sizes[i])); 75 --i; 76 while (i >= 0) 77 delete [] p[i], --i; 78 return -1; 79 } 80 *p[i] = '\0'; 71 p[i] = new char[sizes[i]]; 72 if (!p[i]) { 73 PJ_LOG(3,(THIS_FILE," error: malloc failed to allocate %d bytes", 74 sizes[i])); 75 --i; 76 while (i >= 0) { 77 delete [] p[i]; 78 --i; 79 } 80 return -1; 81 } 82 *p[i] = '\0'; 81 83 } 82 84 83 85 for (i=0; i<COUNT; ++i) { 84 delete [] p[i];86 delete [] p[i]; 85 87 } 86 88
Note: See TracChangeset
for help on using the changeset viewer.