From 55603638a502a8b7bc46a556a7b7108b71996ad6 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sun, 24 Aug 2008 11:29:30 +0200 Subject: wm8739: remove wrong kfree From: Hans Verkuil i2c_client is allocated for us, we should never free it ourselves. Priority: normal Signed-off-by: Hans Verkuil --- linux/drivers/media/video/wm8739.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'linux') diff --git a/linux/drivers/media/video/wm8739.c b/linux/drivers/media/video/wm8739.c index 3ad19cf13..f9d13b89a 100644 --- a/linux/drivers/media/video/wm8739.c +++ b/linux/drivers/media/video/wm8739.c @@ -280,10 +280,8 @@ static int wm8739_probe(struct i2c_client *client, client->addr << 1, client->adapter->name); state = kmalloc(sizeof(struct wm8739_state), GFP_KERNEL); - if (state == NULL) { - kfree(client); + if (state == NULL) return -ENOMEM; - } state->vol_l = 0x17; /* 0dB */ state->vol_r = 0x17; /* 0dB */ state->muted = 0; -- cgit v1.2.3