webrtc-audio-processing-1.3-3.fc42

List of Findings

Error: COMPILER_WARNING (CWE-697): [#def1]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/api/function_view.h:79:17: warning[-Waddress]: the compiler can assume that the address of ‘f’ will never be NULL
#   79 |       : call_(f ? CallFunPtr<typename std::remove_pointer<F>::type> : nullptr) {
#      |               ~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/api/function_view.h:78:20: note: ‘f’ declared here
#   78 |   FunctionView(F&& f)
#      |                ~~~~^
#   77|             nullptr>
#   78|     FunctionView(F&& f)
#   79|->       : call_(f ? CallFunPtr<typename std::remove_pointer<F>::type> : nullptr) {
#   80|       f_.fun_ptr = reinterpret_cast<void (*)()>(f);
#   81|     }

Error: COMPILER_WARNING: [#def2]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/api/function_view.h: scope_hint: In member function ‘rtc::FunctionView<float (float)>::FunctionView<float (&)(float), (void*)0>(float (&)(float))’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/api/function_view.h:79:17: warning[-Wnonnull-compare]: ‘nonnull’ argument ‘f’ compared to NULL
#   79 |       : call_(f ? CallFunPtr<typename std::remove_pointer<F>::type> : nullptr) {
#      |               ~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#   77|             nullptr>
#   78|     FunctionView(F&& f)
#   79|->       : call_(f ? CallFunPtr<typename std::remove_pointer<F>::type> : nullptr) {
#   80|       f_.fun_ptr = reinterpret_cast<void (*)()>(f);
#   81|     }

Error: CPPCHECK_WARNING (CWE-190): [#def3]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/common_audio/signal_processing/levinson_durbin.c:155: error[integerOverflow]: Signed integer overflow for expression 'temp3W32-((int32_t)K_hi*65536)'.
#  153|           // Put K on hi and low format
#  154|           K_hi = (int16_t)(temp3W32 >> 16);
#  155|->         K_low = (int16_t)((temp3W32 - ((int32_t)K_hi * 65536)) >> 1);
#  156|   
#  157|           // Store Reflection coefficient in Q15

Error: CPPCHECK_WARNING (CWE-457): [#def4]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/common_audio/vad/vad_core.c:627: warning[uninitvar]: Uninitialized variable: speech_nb
#  625|   
#  626|     // Do VAD on an 8 kHz signal
#  627|->   vad = WebRtcVad_CalcVad8khz(inst, speech_nb, frame_length / 6);
#  628|   
#  629|     return vad;

Error: GCC_ANALYZER_WARNING (CWE-476): [#def5]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/common_audio/vad/webrtc_vad.c: scope_hint: In function ‘WebRtcVad_Create’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/common_audio/vad/webrtc_vad.c:27:19: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘self’
#   25|     VadInstT* self = (VadInstT*)malloc(sizeof(VadInstT));
#   26|   
#   27|->   self->init_flag = 0;
#   28|   
#   29|     return (VadInst*)self;

Error: COMPILER_WARNING (CWE-563): [#def6]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc/legacy/digital_agc.cc: scope_hint: In function ‘int32_t webrtc::WebRtcAgc_ComputeDigitalGains(DigitalAgc*, const int16_t* const*, size_t, uint32_t, int16_t, int32_t*)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc/legacy/digital_agc.cc:297:11: warning[-Wunused-but-set-variable]: variable ‘L2’ set but not used
#  297 |   int16_t L2;  // samples/subframe
#      |           ^~
#  295|     int16_t k;
#  296|     size_t n, L;
#  297|->   int16_t L2;  // samples/subframe
#  298|   
#  299|     // determine number of samples per ms

Error: COMPILER_WARNING (CWE-393): [#def7]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc2/adaptive_mode_level_estimator.cc: scope_hint: In function ‘float webrtc::{anonymous}::GetLevel(const webrtc::VadLevelAnalyzer::Result&, LevelEstimatorType)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc2/adaptive_mode_level_estimator.cc:45:1: warning[-Wreturn-type]: control reaches end of non-void function
#   45 | }
#      | ^
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc2/rnn_vad/rnn.h:21: included_from: Included from here.
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc2/rnn_vad/rnn.cc:11: included_from: Included from here.
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/api/function_view.h: scope_hint: In instantiation of ‘rtc::FunctionView<RetT(ArgT ...)>::FunctionView(F&&) [with F = float (&)(float); typename std::enable_if<std::is_function<typename std::remove_pointer<typename std::remove_reference<_Up>::type>::type>::value>::type* <anonymous> = 0; RetT = float; ArgT = {float}]’
#/builddir/build/BUILD/webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/agc2/rnn_vad/rnn.cc:379:7:   required from here
#  379 |     : input_layer_(kInputLayerInputSize,
#      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#  380 |                    kInputLayerOutputSize,
#      |                    ~~~~~~~~~~~~~~~~~~~~~~
#  381 |                    kInputDenseBias,
#      |                    ~~~~~~~~~~~~~~~~
#  382 |                    kInputDenseWeights,
#      |                    ~~~~~~~~~~~~~~~~~~~
#  383 |                    TansigApproximated,
#      |                    ~~~~~~~~~~~~~~~~~~~
#  384 |                    DetectOptimization()),
#      |                    ~~~~~~~~~~~~~~~~~~~~~
#   43|         break;
#   44|     }
#   45|-> }
#   46|   
#   47|   }  // namespace

Error: COMPILER_WARNING (CWE-393): [#def8]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/audio_processing_impl.cc: scope_hint: In function ‘webrtc::GainControl::Mode webrtc::{anonymous}::Agc1ConfigModeToInterfaceMode(webrtc::AudioProcessing::Config::GainController1::Mode)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/audio_processing_impl.cc:117:1: warning[-Wreturn-type]: control reaches end of non-void function
#  117 | }
#      | ^
#  115|         return GainControl::kFixedDigital;
#  116|     }
#  117|-> }
#  118|   
#  119|   // Maximum lengths that frame of samples being passed from the render side to

Error: COMPILER_WARNING (CWE-393): [#def9]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/audio_processing_impl.cc: scope_hint: In lambda function
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/audio_processing_impl.cc:1853:13: warning[-Wreturn-type]: control reaches end of non-void function
# 1853 |             default:
#      |             ^~~~~~~
# 1851|               case NoiseSuppresionConfig::kVeryHigh:
# 1852|                 return NsConfig::SuppressionLevel::k21dB;
# 1853|->             default:
# 1854|                 RTC_NOTREACHED();
# 1855|             }

Error: COMPILER_WARNING (CWE-393): [#def10]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc: scope_hint: In function ‘std::string webrtc::{anonymous}::NoiseSuppressionLevelToString(const webrtc::AudioProcessing::Config::NoiseSuppression::Level&)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc:31:1: warning[-Wreturn-type]: control reaches end of non-void function
#   31 | }
#      | ^
#   29|         return "VeryHigh";
#   30|     }
#   31|-> }
#   32|   
#   33|   std::string GainController1ModeToString(

Error: COMPILER_WARNING (CWE-393): [#def11]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc: scope_hint: In function ‘std::string webrtc::{anonymous}::GainController1ModeToString(const webrtc::AudioProcessing::Config::GainController1::Mode&)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc:43:1: warning[-Wreturn-type]: control reaches end of non-void function
#   43 | }
#      | ^
#   41|         return "FixedDigital";
#   42|     }
#   43|-> }
#   44|   
#   45|   std::string GainController2LevelEstimatorToString(

Error: COMPILER_WARNING (CWE-393): [#def12]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc: scope_hint: In function ‘std::string webrtc::{anonymous}::GainController2LevelEstimatorToString(const webrtc::AudioProcessing::Config::GainController2::LevelEstimator&)’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/include/audio_processing.cc:53:1: warning[-Wreturn-type]: control reaches end of non-void function
#   53 | }
#      | ^
#   51|         return "Peak";
#   52|     }
#   53|-> }
#   54|   
#   55|   int GetDefaultMaxInternalRate() {

Error: COMPILER_WARNING: [#def13]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/transient/wpd_tree.cc: scope_hint: In member function ‘__ct_base ’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/modules/audio_processing/transient/wpd_tree.cc:34:59: warning[-Walloc-size-larger-than=]: argument 1 value ‘18446744073709551615’ exceeds maximum object size 9223372036854775807
#   34 |   nodes_.reset(new std::unique_ptr<WPDNode>[num_nodes_ + 1]);
#      |                                                           ^
/usr/include/c++/14/new:133:26: note: in a call to allocation function ‘operator new []’ declared here
#  133 | _GLIBCXX_NODISCARD void* operator new[](std::size_t) _GLIBCXX_THROW (std::bad_alloc)
#      |                          ^
#   32|     // Size is 1 more, so we can use the array as 1-based. nodes_[0] is never
#   33|     // allocated.
#   34|->   nodes_.reset(new std::unique_ptr<WPDNode>[num_nodes_ + 1]);
#   35|   
#   36|     // Create the first node

Error: COMPILER_WARNING (CWE-563): [#def14]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/third_party/pffft/src/pffft.c:218:30: warning[-Wunused-but-set-variable]: variable ‘t’ set but not used
#  218 |   v4sf_union a0, a1, a2, a3, t, u;
#      |                              ^
#  216|   void validate_pffft_simd() {
#  217|     float f[16] = { 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 };
#  218|->   v4sf_union a0, a1, a2, a3, t, u; 
#  219|     memcpy(a0.f, f, 4*sizeof(float));
#  220|     memcpy(a1.f, f+4, 4*sizeof(float));

Error: COMPILER_WARNING (CWE-563): [#def15]
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/third_party/pffft/src/pffft.c: scope_hint: In function ‘validate_pffft_simd’
webrtc-audio-processing-1.3-build/webrtc-audio-processing-1.3/webrtc/third_party/pffft/src/pffft.c:218:33: warning[-Wunused-but-set-variable]: variable ‘u’ set but not used
#  218 |   v4sf_union a0, a1, a2, a3, t, u;
#      |                                 ^
#  216|   void validate_pffft_simd() {
#  217|     float f[16] = { 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 };
#  218|->   v4sf_union a0, a1, a2, a3, t, u; 
#  219|     memcpy(a0.f, f, 4*sizeof(float));
#  220|     memcpy(a1.f, f+4, 4*sizeof(float));

Scan Properties

analyzer-version-clippy1.82.0
analyzer-version-cppcheck2.16.0
analyzer-version-gcc14.2.1
analyzer-version-gcc-analyzer15.0.0
analyzer-version-shellcheck0.10.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-53.us-west-2.compute.internal
mock-configfedora-rawhide-gcc-latest-x86_64
project-namewebrtc-audio-processing-1.3-3.fc42
store-results-to/tmp/tmpt0div3nn/webrtc-audio-processing-1.3-3.fc42.tar.xz
time-created2024-11-13 03:33:17
time-finished2024-11-13 03:35:16
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpt0div3nn/webrtc-audio-processing-1.3-3.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpt0div3nn/webrtc-audio-processing-1.3-3.fc42.src.rpm'
tool-versioncsmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9