From: John Keeping Date: Mon, 25 May 2009 11:24:46 +0000 (+0100) Subject: hwclock: fix mismatched popen/fclose. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=49c0c23d9d90041caab41ca5ea84ac2e014c2ed8;p=util-linux hwclock: fix mismatched popen/fclose. date_child_fp is opened by popen, so should be closed with pclose. Signed-off-by: John Keeping Reviewed-by: WANG Cong --- diff --git a/hwclock/hwclock.c b/hwclock/hwclock.c index 11c606dd..571d63fb 100644 --- a/hwclock/hwclock.c +++ b/hwclock/hwclock.c @@ -676,7 +676,7 @@ interpret_date_string(const char *date_opt, time_t * const time_p) { date_opt, (long) *time_p); } } - fclose(date_child_fp); + pclose(date_child_fp); return retcode; }