Ignore:
Timestamp:
Sep 25, 2017, 11:34:18 AM (7 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
596bc0a
Parents:
e2f7bc3
Message:

Added waitfor test for else clauses and fixed corresponding errors

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libcfa/concurrency/monitor.c

    re2f7bc3 r4cc9b13  
    431431        short actual_count = aggregate( mon_storage, mask );
    432432
     433        if(actual_count == 0) return;
     434
    433435        // Create storage for monitor context
    434436        monitor_ctx( mon_storage, actual_count );
     
    455457
    456458
    457         if( duration == 0 ) return -1;
     459        if( duration == 0 ) {
     460                unlock_all( locks, count );
     461                return;
     462        }
    458463
    459464
     
    642647        for(    thread_desc ** thrd_it = &entry_queue->head;
    643648                *thrd_it;
    644                 thrd_it = &(*thrd_it)->next)
    645         {
     649                thrd_it = &(*thrd_it)->next
     650        ) {
    646651                // For each acceptable check if it matches
    647                 int i;
     652                int i = 0;
    648653                __acceptable_t * end = mask.clauses + mask.size;
    649654                for( __acceptable_t * it = mask.clauses; it != end; it++, i++ ) {
Note: See TracChangeset for help on using the changeset viewer.