From fbe990dfeffd9a9fb3753299b7f632acf6bad037 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Sun, 1 Jan 2023 12:07:28 +0100 Subject: libps: Fix erroneous allocation test --- libps/fmt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libps/fmt.c') diff --git a/libps/fmt.c b/libps/fmt.c index 46416632..853a610c 100644 --- a/libps/fmt.c +++ b/libps/fmt.c @@ -49,7 +49,7 @@ _fmt_create (char *src, int posix, struct ps_fmt_specs *fmt_specs, return ENOMEM; new_fmt = NEW (struct ps_fmt); - if (fmt == NULL) + if (new_fmt == NULL) { FREE (fields); return ENOMEM; -- cgit v1.2.3