Changeset 1073 for trunk/psLib/src/collections/psList.c
- Timestamp:
- Jun 23, 2004, 1:00:17 PM (22 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/collections/psList.c (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/collections/psList.c
r1024 r1073 6 6 * @author Robert Daniel DeSonia, MHPCC 7 7 * 8 * @version $Revision: 1. 6$ $Name: not supported by cvs2svn $9 * @date $Date: 2004-06- 14 19:45:46$8 * @version $Revision: 1.7 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2004-06-23 23:00:15 $ 10 10 * 11 11 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 28 28 29 29 // private functions. 30 psListElem* listGetIterator(psList* list); 31 int listGetIteratorIndex(psList* list); 32 void listSetIterator(psList *list, int where, bool lockList); 30 static psListElem* listGetIterator(psList* list); 31 static int listGetIteratorIndex(psList* list); 32 static void listSetIterator(psList *list, int where, bool lockList); 33 static void listFree(psList *list); 33 34 34 35 … … 36 37 { 37 38 psList *list = psAlloc(sizeof(psList)); 39 p_psMemSetDeallocator(list,(psFreeFcn)listFree); 38 40 39 41 list->size = 0; … … 41 43 list->iter = ITER_INIT_HEAD; 42 44 list->iterIndex = PS_LIST_HEAD; 45 43 46 pthread_mutex_init(&(list->lock),NULL) 44 47 ; … … 51 54 } 52 55 53 void psListFree(psList *list, psFreeFcn elemFree)56 static void listFree(psList *list) 54 57 { 55 58 if (list == NULL) { … … 63 66 psListElem *next = ptr->next; 64 67 65 p _psCustomFree(elemFree, psMemDecrRefCounter(ptr->data));68 psFree(ptr->data); 66 69 psFree(ptr); 67 70 … … 75 78 ; 76 79 77 psFree(list);78 80 } 79 81
Note:
See TracChangeset
for help on using the changeset viewer.
