[FFmpeg-cvslog] [ffmpeg-radio] 09/14: avradio/sdr: Remove code setting frequency from variable being 0

Michael Niedermayer ffmpeg-git at ffmpeg.org
Sat Jul 22 16:55:55 EEST 2023


This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository libavradio.

commit 70d60583648dfd9f1075058c02a0f475598a976a
Author:     Michael Niedermayer <michael at niedermayer.cc>
AuthorDate: Tue Jul 18 22:36:29 2023 +0200
Commit:     Michael Niedermayer <michael at niedermayer.cc>
CommitDate: Sat Jul 22 15:44:54 2023 +0200

    avradio/sdr: Remove code setting frequency from variable being 0
    
    wanted_freq is 0 at this point
    
    Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
---
 libavradio/sdrdemux.c   | 4 ----
 libavradio/sdrinradio.c | 3 ---
 2 files changed, 7 deletions(-)

diff --git a/libavradio/sdrdemux.c b/libavradio/sdrdemux.c
index b22d3fed13..b5e9b9ad04 100644
--- a/libavradio/sdrdemux.c
+++ b/libavradio/sdrdemux.c
@@ -1729,10 +1729,6 @@ static int sdrfile_initial_setup(AVFormatContext *s)
     //After reading the first packet header we return to the begin so the packet can be read whole
     avio_seek(s->pb, 0, SEEK_SET);
 
-    ret = ff_sdr_set_freq(sdr, sdr->wanted_freq);
-    if (ret < 0)
-        return ret;
-
     sdr->read_callback = sdrfile_read_callback;
 
     return ff_sdr_common_init(s);
diff --git a/libavradio/sdrinradio.c b/libavradio/sdrinradio.c
index d569842a9c..d12b0b73fe 100644
--- a/libavradio/sdrinradio.c
+++ b/libavradio/sdrinradio.c
@@ -326,9 +326,6 @@ static int sdrindev_initial_hw_setup(AVFormatContext *s)
         av_log(s, AV_LOG_ERROR, "setSampleRate fail: %s\n", SoapySDRDevice_lastError());
         return AVERROR_EXTERNAL;
     }
-    ret = ff_sdr_set_freq(sdr, sdr->wanted_freq);
-    if (ret < 0)
-        return ret;
 
     //List the available custom options for this specific driver to the user
     arg_info = SoapySDRDevice_getSettingInfo(soapy, &length);



More information about the ffmpeg-cvslog mailing list