summaryrefslogtreecommitdiff
path: root/lib/reed_solomon
diff options
context:
space:
mode:
authorJörn Engel <joern@logfs.org>2007-10-20 23:14:42 +0200
committerDavid Woodhouse <dwmw2@infradead.org>2007-10-20 22:29:09 +0100
commit1dd7fdb163645f453f5ae55686511b6fcc2314cd (patch)
treebf07861981b8dac7a01286e9ef21d96618254ee6 /lib/reed_solomon
parentc32b8dcc45c823cf30dcdf0fc37ee2f6b78f38cb (diff)
[RSLIB] BUG() when passing illegal parameters to decode_rs8() or decode_rs16()
Returning -ERANGE should never happen. Signed-off-by: Jörn Engel <joern@logfs.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'lib/reed_solomon')
-rw-r--r--lib/reed_solomon/decode_rs.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/reed_solomon/decode_rs.c b/lib/reed_solomon/decode_rs.c
index a58df56f09b6..65bc718f0dc0 100644
--- a/lib/reed_solomon/decode_rs.c
+++ b/lib/reed_solomon/decode_rs.c
@@ -39,8 +39,7 @@
/* Check length parameter for validity */
pad = nn - nroots - len;
- if (pad < 0 || pad >= nn)
- return -ERANGE;
+ BUG_ON(pad < 0 || pad >= nn);
/* Does the caller provide the syndrome ? */
if (s != NULL)