LOL, 100l, really fix warning:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>
Sat, 3 Jul 2010 23:24:37 +0000 (23:24 +0000)
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>
Sat, 3 Jul 2010 23:24:37 +0000 (23:24 +0000)
ffmpeg.c: In function 'new_audio_stream':
ffmpeg.c:665: warning: 'best' may be used uninitialized in this function
ffmpeg.c:665: note: 'best' was declared here

Originally committed as revision 24034 to svn://svn.ffmpeg.org/ffmpeg/trunk

ffmpeg.c

index a77093bd98072f965ca189ae2a1218797992fa50..30a319c2442cf5b5f33d8c0e744c8cd27c3ed970 100644 (file)
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -662,7 +662,7 @@ static void choose_sample_rate(AVStream *st, AVCodec *codec)
 {
     if(codec && codec->supported_samplerates){
         const int *p= codec->supported_samplerates;
 {
     if(codec && codec->supported_samplerates){
         const int *p= codec->supported_samplerates;
-        int best;//=0;
+        int best=0;
         int best_dist=INT_MAX;
         for(; *p; p++){
             int dist= abs(st->codec->sample_rate - *p);
         int best_dist=INT_MAX;
         for(; *p; p++){
             int dist= abs(st->codec->sample_rate - *p);