From b31188f465d90c9f2a108ead4bcca4f04f4879cc Mon Sep 17 00:00:00 2001 From: Linas Vepstas Date: Sat, 27 Jan 2001 17:13:01 +0000 Subject: [PATCH] add notes explaining some date funcs git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@3540 57a11ea4-9604-0410-9ed3-97b8803252fd --- src/engine/date.c | 4 ++++ src/engine/date.h | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/src/engine/date.c b/src/engine/date.c index fa486dd7d1..da90c9989f 100644 --- a/src/engine/date.c +++ b/src/engine/date.c @@ -327,6 +327,8 @@ char dateSeparator () /********************************************************************\ * iso 8601 datetimes should look like 1998-07-02 11:00:00.68-05 \********************************************************************/ +/* hack alert -- this routine returns incorrect values for + * dates before 1970 */ Timespec gnc_iso8601_to_timespec(const char *str) @@ -373,6 +375,8 @@ gnc_iso8601_to_timespec(const char *str) /********************************************************************\ \********************************************************************/ +/* hack alert -- this routine returns incorrect values for + * dates before 1970 */ time_t xaccDMYToSec (int day, int month, int year) diff --git a/src/engine/date.h b/src/engine/date.h index 134c327df1..7a59afd331 100644 --- a/src/engine/date.h +++ b/src/engine/date.h @@ -133,6 +133,12 @@ void scanDate (const char *buff, int *day, int *month, int *year); */ char dateSeparator(void); +/* + * hack alert XXX FIXME -- these date routines return incorrect + * values for dates before 1970. Most of them are good only up + * till 2038. This needs fixing ... + */ + time_t xaccDMYToSec (int day, int month, int year); time_t xaccScanDateS (const char *buff);