if(sta->client_mac_addr == client_mac_addr) {
/*mac address is the same change only rate*/
pthread_mutex_lock( &frm_fwp_state->mutex );
+ ul_logmsg("Mutex: locked - update station\n");
sta->rate = rate;
pthread_mutex_unlock( &frm_fwp_state->mutex );
+ ul_logmsg("Mutex: unlocked - update station\n");
//TODO: debug
fres_contract_broker_redistribute_spare_capacity(frm_fwp_state->fcb, restype, resid, &env);
if (forb_exception_occurred(&env)) {
new_to_add->rate = rate;
new_to_add->client_mac_addr = client_mac_addr;
pthread_mutex_lock( &frm_fwp_state->mutex );
+ ul_logmsg("Mutex: locked - add new station\n");
sta_list_ins_tail(&frm_fwp_state->sta_list, new_to_add);
pthread_mutex_unlock( &frm_fwp_state->mutex );
+ ul_logmsg("Mutex: unlocked - add new station\n");
return 0;
}