summaryrefslogtreecommitdiff
path: root/Modules/audioop.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/audioop.c')
-rw-r--r--Modules/audioop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/audioop.c b/Modules/audioop.c
index 2d287f249b..0358147f92 100644
--- a/Modules/audioop.c
+++ b/Modules/audioop.c
@@ -1320,7 +1320,7 @@ audioop_ratecv_impl(PyModuleDef *module, Py_buffer *fragment, int width, int nch
/* divide weightA and weightB by their greatest common divisor */
d = gcd(weightA, weightB);
weightA /= d;
- weightA /= d;
+ weightB /= d;
if ((size_t)nchannels > PY_SIZE_MAX/sizeof(int)) {
PyErr_SetString(PyExc_MemoryError,