source:
issm/oecreview/Archive/11681-11700/ISSM-11691-11692.diff
Last change on this file was 11991, checked in by , 13 years ago | |
---|---|
File size: 1015 bytes |
-
proj/ice/larour/issm-uci-clean/trunk-jpl/src/c/shared/Alloc/alloc.cpp
66 66 return memptr; 67 67 } 68 68 69 void xfree( 69 void xfree(void* *pv){ 70 70 71 if (pv && *pv) { 72 71 if (pv && *pv){ 73 72 #ifdef _SERIAL_ 74 mxFree(*pv);73 mxFree(*pv); 75 74 #else 76 free(*pv);75 free(*pv); 77 76 #endif 78 77 79 78 *pv=NULL; 80 79 } 81 80 } 82 81 83 void xdelete( Matrix** pv){ 84 85 if (pv && *pv) { 86 82 void xdelete(Matrix** pv){ 83 if (pv && *pv){ 87 84 delete *pv; 88 85 *pv=NULL; 89 86 } 90 87 } 91 88 92 void xdelete( Vector** pv){ 93 94 if (pv && *pv) { 95 96 delete *pv; 89 void xdelete(Vector** pv){ 90 if (pv && *pv){ 91 //delete *pv; 92 VecFree(&(*pv)->vector); 97 93 *pv=NULL; 98 94 } 99 95 } 100 96 101 97 102 void* xrealloc 98 void* xrealloc( void* pv, int size){ 103 99 104 100 register void* value=NULL; 105 101
Note:
See TracBrowser
for help on using the repository browser.