# HG changeset patch # User michael # Date 1208399400 0 # Node ID eb001d01785cc7fa34021ac98c1fa5cdfc81159d # Parent 873e705732ca2137049f091fbb50e14ad6655bff simplify diff -r 873e705732ca -r eb001d01785c alac.c --- a/alac.c Wed Apr 16 21:50:41 2008 +0000 +++ b/alac.c Thu Apr 17 02:30:00 2008 +0000 @@ -184,11 +184,9 @@ int k; /* size of extra bits */ /* read k, that is bits as is */ - k = 31 - rice_kmodifier - count_leading_zeros((history >> 9) + 3); + k = 31 - count_leading_zeros((history >> 9) + 3); - if (k < 0) - k += rice_kmodifier; - else + if (k >= rice_kmodifier) k = rice_kmodifier; if (k != 1) {