Changeset 780:2d85b79204bd in mediastreamer2


Ignore:
Timestamp:
Nov 23, 2009 2:51:36 PM (4 years ago)
Author:
smorlat <smorlat@…>
Branch:
default
Message:

fix crash in equalizer

git-svn-id: svn+ssh://svn.savannah.nongnu.org/linphone/trunk@768 3f6dc0c8-ddfe-455d-9043-3cd528dc4637

File:
1 edited

Legend:

Unmodified
Added
Removed
  • linphone/mediastreamer2/src/equalizer.c

    r612 r780  
    4242typedef struct _EqualizerState{ 
    4343        int rate; 
    44         int nfft; //number of fft points in time 
     44        int nfft; /*number of fft points in time*/ 
    4545        ms_word16_t *fft_cpx; 
    4646        int fir_len; 
     
    5959} 
    6060 
     61/* TODO: rate also beyond 8000 */ 
    6162static EqualizerState * equalizer_state_new(int nfft){ 
    6263        EqualizerState *s=(EqualizerState *)ms_new0(EqualizerState,1); 
     
    146147                equalizer_point_set(s, i, f, gain); 
    147148        } 
    148         while (i<TAPS && (gain>1.1 || gain<0.9)); 
     149        while (i < s->nfft/2 && (gain>1.1 || gain<0.9)); 
    149150        i = mid; 
    150151        do {    /* ... and here +delta, as to  */ 
Note: See TracChangeset for help on using the changeset viewer.