From 5b412ffb6b23e5f9702c3115a88556af4b35d990 Mon Sep 17 00:00:00 2001 From: Alexander Leidinger Date: Tue, 17 Nov 2009 07:29:35 +0000 Subject: [PATCH] Fix small resource leak (memory). Reviewed by: gad MFC after: 1 week --- bin/ps/keyword.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/ps/keyword.c b/bin/ps/keyword.c index 609c52e363b9..4524d9956665 100644 --- a/bin/ps/keyword.c +++ b/bin/ps/keyword.c @@ -330,6 +330,7 @@ findvar(char *p, int user, char **header) errx(1, "malloc failed"); snprintf(realfmt, rflen, "%s=%s", v->alias, hp); parsefmt(realfmt, user); + free(realfmt); } return ((VAR *)NULL); }