Changeset 5302:4d77c9526beb in roaraudio for roard/midi.c


Ignore:
Timestamp:
11/26/11 15:49:52 (12 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

added roar_buffer_foreach() (See: #126)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • roard/midi.c

    r5301 r5302  
    583583 send_clock = streams_get_flag(id, ROAR_FLAG_SYNC); 
    584584 
    585  while (buf != NULL) { 
     585 roar_buffer_foreach(buf) { 
    586586  if ( roar_buffer_get_data(buf, &bufdata) == -1 ) { 
    587587   return -1; 
     
    638638   } 
    639639  } 
    640  
    641   if ( roar_buffer_get_next(buf, &buf) == -1 ) 
    642    buf = NULL; 
    643640 } 
    644641 
     
    653650 void                      * bufdata; 
    654651 
    655  while (buf != NULL) { 
     652 roar_buffer_foreach(buf) { 
    656653  if ( roar_buffer_get_data(buf, &bufdata) == -1 ) { 
    657654   return -1; 
     
    662659  if ( ssynth_eval_message(mes) == -1 ) 
    663660   return -1; 
    664  
    665   if ( roar_buffer_get_next(buf, &buf) == -1 ) 
    666    buf = NULL; 
    667661 } 
    668662 
     
    10171011 ROAR_DBG("midi_cb_readbuf(void) = ?"); 
    10181012 
    1019  while (buf != NULL) { 
     1013 roar_buffer_foreach(buf) { 
    10201014  ROAR_DBG("midi_cb_readbuf(void): buf=%p", buf); 
    10211015 
     
    10381032    break; 
    10391033  } 
    1040  
    1041   if ( roar_buffer_get_next(buf, &buf) == -1 ) 
    1042    buf = NULL; 
    10431034 } 
    10441035 
Note: See TracChangeset for help on using the changeset viewer.