ext/iodine/fio.c
/** Clears all the existing callbacks for the event. */
Clears all the existing callbacks for the event.
Clears all the existing callbacks for the event .
void fio_state_callback_clear(callback_type_e c_type) {
  if ((int)c_type < 0 || c_type > FIO_CALL_NEVER)
    return;
  fio_lock(&callback_collection[c_type].lock);
  fio_state_callback_ensure(&callback_collection[c_type]);
  while (fio_ls_embd_any(&callback_collection[c_type].callbacks)) {
    callback_data_s *tmp = FIO_LS_EMBD_OBJ(
        callback_data_s, node,
        fio_ls_embd_shift(&callback_collection[c_type].callbacks));
    free(tmp);
  }
  fio_unlock(&callback_collection[c_type].lock);
}
void fio_state_callback_clear ( callback_type_e c_type ) { if ( ( int ) c_type < 0 || c_type > FIO_CALL_NEVER ) return ; fio_lock ( & callback_collection [ c_type ] . lock ) ; fio_state_callback_ensure ( & callback_collection [ c_type ] ) ; while ( fio_ls_embd_any ( & callback_collection [ c_type ] . callbacks ) ) { callback_data_s * tmp = FIO_LS_EMBD_OBJ ( callback_data_s , node , fio_ls_embd_shift ( & callback_collection [ c_type ] . callbacks ) ) ; free ( tmp ) ; } fio_unlock ( & callback_collection [ c_type ] . lock ) ; }
Clears all the existing callbacks for the event.
Clears all the existing callbacks for the event .