diff --git a/libswresample/rematrix.c b/libswresample/rematrix.c
index eaf7653735c90b94766b74685f5a2c8094b0d6b4..87fd35a4773616a508873311799ffde42edbd07e 100644
--- a/libswresample/rematrix.c
+++ b/libswresample/rematrix.c
@@ -82,7 +82,7 @@ static int sane_layout(int64_t layout){
 }
 
 int swr_rematrix_init(SwrContext *s){
-    int i, j, in_i, out_i;
+    int i, j, out_i;
     double matrix[64][64]={{0}};
     int64_t unaccounted= s->in_ch_layout & ~s->out_ch_layout;
     double maxcoef=0;