Changeset a933dcf4 for src/libcfa


Ignore:
Timestamp:
May 2, 2017, 2:42:14 PM (8 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:
b510ac2
Parents:
5783e94
Message:
  • updated internal scheduler test for multi monitors
  • fixed branding for monitors
File:
1 edited

Legend:

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

    r5783e94 ra933dcf4  
    1616
    1717#include "monitor"
     18
     19#include <stdlib>
    1820
    1921#include "kernel_private.h"
     
    351353                LIB_DEBUG_PRINT_SAFE("Branding\n");
    352354                assertf( thrd->current_monitors != NULL, "No current monitor to brand condition", thrd->current_monitors );
    353                 this->monitors = thrd->current_monitors;
    354355                this->monitor_count = thrd->current_monitor_count;
     356
     357                this->monitors = malloc( this->monitor_count * sizeof( *this->monitors ) );
     358                for( int i = 0; i < this->monitor_count; i++ ) {
     359                        this->monitors[i] = thrd->current_monitors[i];
     360                }
    355361        }
    356362}
Note: See TracChangeset for help on using the changeset viewer.