[pulseaudio-discuss] [PATCH 07/23] echo-cancel: Fix zeroing of w in AEC_leaky()

Peter Meerwald pmeerw at pmeerw.net
Wed Feb 13 08:26:54 PST 2013


From: Peter Meerwald <p.meerwald at bct-electronic.com>

bug probably caused by alignment requirement; sizeof(a->w) is a pointer, sizeof(a->w_arr) is an array

Signed-off-by: Peter Meerwald <p.meerwald at bct-electronic.com>
---
 src/modules/echo-cancel/adrian-aec.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/echo-cancel/adrian-aec.c b/src/modules/echo-cancel/adrian-aec.c
index 9134212..c079e65 100644
--- a/src/modules/echo-cancel/adrian-aec.c
+++ b/src/modules/echo-cancel/adrian-aec.c
@@ -174,7 +174,7 @@ static void AEC_leaky(AEC *a)
     } else if (1 == a->hangover) {
       --(a->hangover);
       // My Leaky NLMS is to erase vector w when hangover expires
-      memset(a->w, 0, sizeof(a->w));
+      memset(a->w_arr, 0, sizeof(a->w_arr));
     }
   }
 }
-- 
1.7.9.5



More information about the pulseaudio-discuss mailing list