From 7d22d3cdc9c0a03158f550c35a6a26417869ee92 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Tue, 9 Aug 2005 03:21:15 +0000 Subject: Do not ignore return value of localsub() in localtime_r() --- lib/libc/time/localtime.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/libc') diff --git a/lib/libc/time/localtime.c b/lib/libc/time/localtime.c index 4de725bbac4..5245de78bbe 100644 --- a/lib/libc/time/localtime.c +++ b/lib/libc/time/localtime.c @@ -1,4 +1,4 @@ -/* $OpenBSD: localtime.c,v 1.27 2005/08/08 08:05:38 espie Exp $ */ +/* $OpenBSD: localtime.c,v 1.28 2005/08/09 03:21:14 millert Exp $ */ /* ** This file is in the public domain, so clarified as of ** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). @@ -1171,7 +1171,7 @@ struct tm *p_tm; { _THREAD_PRIVATE_MUTEX_LOCK(lcl); tzset_basic(); - localsub(timep, 0L, p_tm); + p_tm = localsub(timep, 0L, p_tm); _THREAD_PRIVATE_MUTEX_UNLOCK(lcl); return p_tm; } -- cgit v1.2.3