From: Jeff Dike Date: Tue, 16 Oct 2007 08:26:40 +0000 (-0700) Subject: uml: fix error cleanup ordering X-Git-Tag: v3.12-rc1~26096 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=79f662334fefa2dd3fdf66c44a4d2dca5e378ab4;p=kernel%2Fkernel-generic.git uml: fix error cleanup ordering I messed up the error cleanup ordering in the console port driver. Signed-off-by: Jeff Dike Cc: Paolo 'Blaisorblade' Giarrusso Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/arch/um/drivers/port_kern.c b/arch/um/drivers/port_kern.c index 1c8efd9..d8acf74 100644 --- a/arch/um/drivers/port_kern.c +++ b/arch/um/drivers/port_kern.c @@ -216,10 +216,10 @@ void *port_data(int port_num) .telnetd_pid = -1 }); goto out; - out_free: - kfree(port); out_close: os_close_file(fd); + out_free: + kfree(port); out: up(&ports_sem); return dev;