Skip to content
Commit e60b13e4 authored by Anton Protopopov's avatar Anton Protopopov Committed by David S. Miller
Browse files

mISDN: prevent possible NULL pointer dereference



A return value of the bchannel_get_rxbuf() function is compared with the
positive ENOMEM value instead of the negative -ENOMEM value to detect a
memory allocation problem. Thus, after a possible memory allocation
failure the bc->bch.rx_skb will be NULL which will lead to a NULL
pointer dereference.

Signed-off-by: default avatarAnton Protopopov <a.s.protopopov@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 449f14f0
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment