From: Armin Schindler Date: Tue, 17 Jul 2007 11:04:23 +0000 (-0700) Subject: i4l: leak in eicon/idifunc.c X-Git-Tag: v2.6.23-rc1~676 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2bf68a3699601bd3e53b4efce7f2d780e243aa35;p=linux-2.6 i4l: leak in eicon/idifunc.c coverity spotted a possible leak in the idifunc.c file (bug id #1252), in um_new_card(), if the diva_user_mode_idi_create_adapter() fails, we dont free the memory allocated for card Signed-off-by: Eric Sesterhenn Acked-by: Armin Schindler Cc: Karsten Keil Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/isdn/hardware/eicon/idifunc.c b/drivers/isdn/hardware/eicon/idifunc.c index 4cbc68cf4d..db87d51054 100644 --- a/drivers/isdn/hardware/eicon/idifunc.c +++ b/drivers/isdn/hardware/eicon/idifunc.c @@ -106,6 +106,7 @@ static void um_new_card(DESCRIPTOR * d) } else { DBG_ERR(("could not create user mode idi card %d", adapter_nr)); + diva_os_free(0, card); } }