Skip to content
Commit 3f50b022 authored by Kevin Winchester's avatar Kevin Winchester Committed by Dave Airlie
Browse files

agp: correct missing cleanup on error in agp_add_bridge



While investigating a kmemleak detected leak, I encountered the
agp_add_bridge function.  It appears to be responsible for freeing
the agp_bridge_data in the case of a failure, but it is only doing
so for some errors.

Fix it to always free the bridge data if a failure condition is
encountered.

Signed-off-by: default avatarKevin Winchester <kjwinchester@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent 22763c5c
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