Changeset 4278:3d831ee2a440 in roaraudio


Ignore:
Timestamp:
08/28/10 19:57:56 (14 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

implemented streams_lzm_get()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • roard/streams.c

    r4272 r4278  
    11531153} 
    11541154 
    1155 struct roar_stream_ltm * streams_lzm_get(int id, int mt, int window); 
     1155struct roar_stream_ltm * streams_lzm_get(int id, int mt, int window) { 
     1156 struct roar_stream_server * ss; 
     1157 struct roar_stream_ltm *    ltm = NULL; 
     1158 int i; 
     1159 
     1160 _CHECK_SID(id); 
     1161 
     1162 if ( (ss = g_streams[id]) == NULL ) 
     1163  return -1; 
     1164 
     1165 for (i = 0; i < MAX_LTM_WINDOWS_PER_STREAM; i++) { 
     1166  if ( ss->ltm[i].refc && ss->ltm[i].window == window ) { 
     1167   ltm = &(ss->ltm[i]); 
     1168   break; 
     1169  } 
     1170 } 
     1171 
     1172 if ( ltm == NULL ) 
     1173  return NULL; 
     1174 
     1175 if ( (ltm->mt & mt) != mt ) 
     1176  return NULL; 
     1177 
     1178 return ltm; 
     1179} 
    11561180 
    11571181 
Note: See TracChangeset for help on using the changeset viewer.