isdn: off by one in connect_res()
authorDan Carpenter <dan.carpenter@oracle.com>
Sun, 1 Feb 2015 20:54:25 +0000 (23:54 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 3 Feb 2015 03:33:18 +0000 (19:33 -0800)
commitc101cff9010083a8796353a75673fd100b077b79
tree34624bfa19044077adcc511bef57c764ef1f49ee
parent3ae55826ae15cfb3bfa58d0dac29c53fc5fd1088
isdn: off by one in connect_res()

The bug here is that we use "Reject" as the index into the cau_t[] array
in the else path.  Since the cau_t[] has 9 elements if Reject == 9 then
we are reading beyond the end of the array.

My understanding of the code is that it's saying that if Reject is 1 or
too high then that's invalid and we should hang up.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/isdn/hardware/eicon/message.c