From: Paul Eggert Date: Sun, 23 Jan 2022 19:24:35 +0000 (-0800) Subject: copy: remove unnecessary ‘free’ X-Git-Tag: v9.1~132 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fbc7958b36dd5bbc56f5cb4368abd6734ebff0a3;p=thirdparty%2Fcoreutils.git copy: remove unnecessary ‘free’ * src/copy.c (copy_reg): Remove a ‘free’ call that does nothing because its argument is always a null pointer, starting with 2007-11-1608:31:15Z!jim@meyering.net. --- diff --git a/src/copy.c b/src/copy.c index 753d6ccd98..b2e3cb1f76 100644 --- a/src/copy.c +++ b/src/copy.c @@ -1078,7 +1078,6 @@ copy_reg (char const *src_name, char const *dst_name, { char *buf; char *buf_alloc = NULL; - char *name_alloc = NULL; int dest_desc; int dest_errno; int source_desc; @@ -1459,7 +1458,6 @@ close_src_desc: } free (buf_alloc); - free (name_alloc); return return_val; }