Modularizando o src
Dependencies: EALib EthernetInterface_vz mbed-rtos mbed
Fork of header_main_colinas_V0-20-09-14 by
Diff: call_box_manager.cpp
- Revision:
- 108:18a3702650f3
- Parent:
- 106:a34fcf9f0e02
- Child:
- 109:a5b8264ffbbc
diff -r cf1e43414adb -r 18a3702650f3 call_box_manager.cpp --- a/call_box_manager.cpp Mon Mar 16 14:05:05 2015 +0000 +++ b/call_box_manager.cpp Wed Mar 18 13:33:54 2015 +0000 @@ -8,7 +8,10 @@ Call_Box * cb = NULL; for( register int i = 0; i < v_cb->size(); i++ ){ cb = ( Call_Box * )v_cb->get_element( i ); - if( cb->get_ext() == ext ) return( cb ); + if( cb != NULL ) + { + if( cb->get_ext() == ext ) return( cb ); + } } return( NULL ); } @@ -49,11 +52,14 @@ } -//FiXME se validar, nao preciso de tantos parametros ... +//FiXME remove myself +//funcao fora de uso, nao usar, +/* void registry_aging( Vector * v_cb, uint8_t * data, uint8_t * write_buffer ){ for( register int i = 0; i < v_cb->size(); i++ ){ Call_Box * cb = (Call_Box * )v_cb->get_element( i ); - if( cb->is_timeout() ){ + //if ( cb->is_timeout() ) + { if( debug_aging ) debug_msg("sands for %d", cb->get_ext() ); if( cb->has_next_try() == false ){ if( debug_aging ) debug_msg( "time to really go ( ext %d removed )", cb->get_ext() ); @@ -64,6 +70,7 @@ } } } +*/ //void wake_all_up( Vector * v_cb, uint8_t * data, uint8_t * write_buffer ){ void wake_all_up( Vector * v_cb )