tcsh/tcsh-6.19.00-027-fix-memory-leak-when-cdpath-fails.patch
David Kaspar [Dee'Kej] a88e18c024 tcsh-6.19.00-027-fix-memory-leak-when-cdpath-fails.patch added
> fix memory leak when cdpath fails to find a matching path (David Kaspar)
2016-05-03 17:11:24 +02:00

26 lines
525 B
Diff

From 554366732a43be40ec8e1394c366c9ae48f37b49 Mon Sep 17 00:00:00 2001
From: christos <christos>
Date: Fri, 8 Apr 2016 16:10:52 +0000
Subject: [PATCH] fix memory leak when cdpath fails to find a matching path
(David Kaspar)
---
sh.dir.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/sh.dir.c b/sh.dir.c
index 6921a32..e583bdc 100644
--- a/sh.dir.c
+++ b/sh.dir.c
@@ -676,6 +676,7 @@ dfollow(Char *cp, int old)
cleanup_until(cp);
return dgoto(cp);
}
+ xfree(dp);
}
xfree(buf.s);
}
--
2.5.5