Author: ngie Date: Mon Oct 13 02:44:35 2014 New Revision: 273024 URL: https://svnweb.freebsd.org/changeset/base/273024
Log: Only test the return value in mktime_negyear Testing for the errno is an optional requirement according to POSIX, and FreeBSD doesn't document that errno would be set on failure with mktime Submitted by: pho Sponsored by: EMC / Isilon Storage Division Modified: head/contrib/netbsd-tests/lib/libc/time/t_mktime.c Modified: head/contrib/netbsd-tests/lib/libc/time/t_mktime.c ============================================================================== --- head/contrib/netbsd-tests/lib/libc/time/t_mktime.c Mon Oct 13 02:32:37 2014 (r273023) +++ head/contrib/netbsd-tests/lib/libc/time/t_mktime.c Mon Oct 13 02:44:35 2014 (r273024) @@ -72,7 +72,12 @@ ATF_TC_BODY(mktime_negyear, tc) errno = 0; t = mktime(&tms); +#if defined(__FreeBSD__) + /* Open Group says "and may set errno to indicate the error" */ + ATF_REQUIRE(t == (time_t)-1); +#else ATF_REQUIRE_ERRNO(0, t != (time_t)-1); +#endif } ATF_TC(timegm_epoch); _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"