IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 1542


Ignore:
Timestamp:
Aug 13, 2004, 3:48:45 PM (22 years ago)
Author:
desonia
Message:

found some points where the mutex is not released upon certain error conditions.

Location:
trunk/psLib/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/collections/psList.c

    r1440 r1542  
    77 *  @author Robert Daniel DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2004-08-09 23:34:57 $
     9 *  @version $Revision: 1.16 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2004-08-14 01:48:45 $
    1111 *
    1212 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    196196        if (which == PS_LIST_UNKNOWN) {
    197197            psError(__func__, "Failed to find item in given psList.");
     198            pthread_mutex_unlock(&list->lock)
     199            ;
    198200            return false;
    199201        }
     
    206208    if (elem == NULL) {
    207209        psError(__func__, "Couldn't position to given index (%d) to remove element from list.", which);
     210        pthread_mutex_unlock(&list->lock)
     211        ;
    208212        return false;
    209213    }
     
    270274    if (where >= (int)list->size) {
    271275        list->iter = NULL;
     276        if (lockList) {
     277            pthread_mutex_unlock(&list->lock)
     278            ;
     279        }
    272280        return;
    273281    }
  • trunk/psLib/src/types/psList.c

    r1440 r1542  
    77 *  @author Robert Daniel DeSonia, MHPCC
    88 *
    9  *  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2004-08-09 23:34:57 $
     9 *  @version $Revision: 1.16 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2004-08-14 01:48:45 $
    1111 *
    1212 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    196196        if (which == PS_LIST_UNKNOWN) {
    197197            psError(__func__, "Failed to find item in given psList.");
     198            pthread_mutex_unlock(&list->lock)
     199            ;
    198200            return false;
    199201        }
     
    206208    if (elem == NULL) {
    207209        psError(__func__, "Couldn't position to given index (%d) to remove element from list.", which);
     210        pthread_mutex_unlock(&list->lock)
     211        ;
    208212        return false;
    209213    }
     
    270274    if (where >= (int)list->size) {
    271275        list->iter = NULL;
     276        if (lockList) {
     277            pthread_mutex_unlock(&list->lock)
     278            ;
     279        }
    272280        return;
    273281    }
Note: See TracChangeset for help on using the changeset viewer.