summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Cox <alan@lxorguk.ukuu.org.uk>2009-04-06 17:33:48 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-06 14:36:32 -0700
commit8d5a05da823ebd83a5147e1bfe19036a57a4d33c (patch)
treea692cc97fd67c5249a4fc76a98fda2aad297e7a7
parent5c9f5806836a9079d6c2d38d567d5f0662863bf4 (diff)
downloadlinux-3.10-8d5a05da823ebd83a5147e1bfe19036a57a4d33c.tar.gz
linux-3.10-8d5a05da823ebd83a5147e1bfe19036a57a4d33c.tar.bz2
linux-3.10-8d5a05da823ebd83a5147e1bfe19036a57a4d33c.zip
ucc: Fix leaky error path
Found by Daniel Marjamäki using cppcheck Signed-off-by: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--drivers/serial/ucc_uart.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/serial/ucc_uart.c b/drivers/serial/ucc_uart.c
index 315a9333ca3..7de66c06b05 100644
--- a/drivers/serial/ucc_uart.c
+++ b/drivers/serial/ucc_uart.c
@@ -1274,6 +1274,7 @@ static int ucc_uart_probe(struct of_device *ofdev,
if (!iprop) {
iprop = of_get_property(np, "device-id", NULL);
if (!iprop) {
+ kfree(qe_port);
dev_err(&ofdev->dev, "UCC is unspecified in "
"device tree\n");
return -EINVAL;