소스 검색

Merge pull request #62156 from madmiraal/fix-61457

Ensure AudioFrame variables l and r are always initialised
Rémi Verschelde 3 년 전
부모
커밋
d572d3d2ab
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      core/math/audio_frame.h

+ 1 - 1
core/math/audio_frame.h

@@ -52,7 +52,7 @@ static const float AUDIO_MIN_PEAK_DB = -200.0f; // linear2db(AUDIO_PEAK_OFFSET)
 
 struct AudioFrame {
 	//left and right samples
-	float l, r;
+	float l = 0.f, r = 0.f;
 
 	_ALWAYS_INLINE_ const float &operator[](int idx) const { return idx == 0 ? l : r; }
 	_ALWAYS_INLINE_ float &operator[](int idx) { return idx == 0 ? l : r; }