From 8375d5c12b63ec99141bfb1b70c0f2cfe70b564b Mon Sep 17 00:00:00 2001
From: Laurent Bercot
Date: Fri, 2 Feb 2018 00:59:36 +0000
Subject: Fix HASSIGNEDSIGNED sysdeps macros, add localtm_from_ltm64 tolerance
for 64-bit time_t
---
AUTHORS | 1 +
NEWS | 5 +++++
configure | 8 ++++----
doc/index.html | 2 +-
doc/license.html | 2 +-
doc/upgrade.html | 6 ++++++
package/deps.mak | 2 +-
package/info | 2 +-
src/libstddjb/localtm_from_ltm64.c | 3 +++
9 files changed, 23 insertions(+), 8 deletions(-)
diff --git a/AUTHORS b/AUTHORS
index fed2d88..9b95aa5 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -30,3 +30,4 @@ Thanks to:
Martin Misuth
Michael Zuo
Éric Le Bihan
+ Samuel Holland
diff --git a/NEWS b/NEWS
index d3500a7..33290dc 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,10 @@
Changelog for skalibs.
+In 2.6.3.2
+----------
+
+ - Bugfixes.
+
In 2.6.3.1
----------
diff --git a/configure b/configure
index 3fddbfd..d6213c4 100755
--- a/configure
+++ b/configure
@@ -166,11 +166,11 @@ trytypes () {
./output-types | grep -F signed | while read key value ; do
caps=$(echo $key | sed s/:\$// | tr a-z A-Z)
if test $value = yes ; then
- echo "#define ${package_macro_name}_HASSIGNED${caps}"
- echo "#undef ${package_macro_name}_HASUNSIGNED${caps}"
+ echo "#define ${package_macro_name}_HAS${caps}"
+ echo "#undef ${package_macro_name}_HASUN${caps}"
else
- echo "#undef ${package_macro_name}_HASSIGNED${caps}"
- echo "#define ${package_macro_name}_HASUNSIGNED${caps}"
+ echo "#undef ${package_macro_name}_HAS${caps}"
+ echo "#define ${package_macro_name}_HASUN${caps}"
fi >> $sysdeps/sysdeps.h
done
rm -f output-types
diff --git a/doc/index.html b/doc/index.html
index de6b3a2..7eb9ed8 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -60,7 +60,7 @@ with a standard C development environment
Download
- - The current released version of skalibs is 2.6.3.1.
+ - The current released version of skalibs is 2.6.3.2.
- Alternatively, you can checkout a copy of the
skalibs
git repository:
diff --git a/doc/license.html b/doc/license.html
index 61845f6..30d7bee 100644
--- a/doc/license.html
+++ b/doc/license.html
@@ -74,7 +74,7 @@ color, or different text font.
I am aware that the previous restrictions sound completely
ridiculous while the official skalibs documentation is incomplete.
-As of 2.6.3.1, I'm not going to enforce those restrictions, but if you're
+As of 2.6.3.2, I'm not going to enforce those restrictions, but if you're
going to provide documentation for skalibs, don't keep it to yourself,
please send it to me instead. :-)
diff --git a/doc/upgrade.html b/doc/upgrade.html
index 5c3ec36..6568ca7 100644
--- a/doc/upgrade.html
+++ b/doc/upgrade.html
@@ -16,6 +16,12 @@
skarnet.org
+ in 2.6.3.2
+
+
+ - No functional changes.
+
+
in 2.6.3.1
diff --git a/package/deps.mak b/package/deps.mak
index 5f58c9f..4120c48 100644
--- a/package/deps.mak
+++ b/package/deps.mak
@@ -392,7 +392,7 @@ src/libstddjb/leapsecs_add.o src/libstddjb/leapsecs_add.lo: src/libstddjb/leapse
src/libstddjb/leapsecs_sub.o src/libstddjb/leapsecs_sub.lo: src/libstddjb/leapsecs_sub.c src/libstddjb/djbtime-internal.h src/include/skalibs/uint64.h
src/libstddjb/leapsecs_table.o src/libstddjb/leapsecs_table.lo: src/libstddjb/leapsecs_table.c src/libstddjb/djbtime-internal.h src/include/skalibs/tai.h src/include/skalibs/uint64.h
src/libstddjb/localtm_fmt.o src/libstddjb/localtm_fmt.lo: src/libstddjb/localtm_fmt.c src/include/skalibs/djbtime.h src/include/skalibs/types.h
-src/libstddjb/localtm_from_ltm64.o src/libstddjb/localtm_from_ltm64.lo: src/libstddjb/localtm_from_ltm64.c src/include/skalibs/djbtime.h src/include/skalibs/tai.h src/include/skalibs/uint64.h
+src/libstddjb/localtm_from_ltm64.o src/libstddjb/localtm_from_ltm64.lo: src/libstddjb/localtm_from_ltm64.c src/include/skalibs/djbtime.h src/include/skalibs/sysdeps.h src/include/skalibs/tai.h src/include/skalibs/uint64.h
src/libstddjb/localtm_from_sysclock.o src/libstddjb/localtm_from_sysclock.lo: src/libstddjb/localtm_from_sysclock.c src/include/skalibs/djbtime.h src/include/skalibs/uint64.h
src/libstddjb/localtm_from_tai.o src/libstddjb/localtm_from_tai.lo: src/libstddjb/localtm_from_tai.c src/include/skalibs/djbtime.h src/include/skalibs/uint64.h
src/libstddjb/localtm_from_utc.o src/libstddjb/localtm_from_utc.lo: src/libstddjb/localtm_from_utc.c src/include/skalibs/djbtime.h src/include/skalibs/uint64.h
diff --git a/package/info b/package/info
index 5467836..6f4b721 100644
--- a/package/info
+++ b/package/info
@@ -1,4 +1,4 @@
package=skalibs
-version=2.6.3.1
+version=2.6.3.2
category=prog
package_macro_name=SKALIBS
diff --git a/src/libstddjb/localtm_from_ltm64.c b/src/libstddjb/localtm_from_ltm64.c
index e2cc382..76703da 100644
--- a/src/libstddjb/localtm_from_ltm64.c
+++ b/src/libstddjb/localtm_from_ltm64.c
@@ -5,6 +5,7 @@
#define _BSD_SOURCE
#endif
+#include
#include
#include
#include
@@ -15,7 +16,9 @@ int localtm_from_ltm64 (struct tm *l, uint64_t uu, int tz)
{
if (uu < TAI_MAGIC) return (errno = EINVAL, 0) ;
uu -= TAI_MAGIC ;
+#if SKALIBS_SIZEOFTIME != 8
if (uu > 0xFFFFFFFFUL) return (errno = EOVERFLOW, 0) ;
+#endif
{
time_t u = (time_t)uu ;
if (tz ? !localtime_r(&u, l) : !gmtime_r(&u, l)) return 0 ;
--
cgit v1.2.3