]> diplodocus.org Git - nmh/commitdiff
datetime.c: Move interface to own file.
authorRalph Corderoy <ralph@inputplus.co.uk>
Wed, 15 Nov 2017 23:36:42 +0000 (23:36 +0000)
committerRalph Corderoy <ralph@inputplus.co.uk>
Thu, 16 Nov 2017 00:03:51 +0000 (00:03 +0000)
Makefile.am
h/icalendar.h
sbr/datetime.c
sbr/datetime.h [new file with mode: 0644]
uip/mhical.c

index b9252d0..4efbe36 100644 (file)
@@ -378,6 +378,7 @@ noinst_HEADERS = \
     sbr/crawl_folders.h \
     sbr/credentials.h \
     sbr/ctype-checked.h \
     sbr/crawl_folders.h \
     sbr/credentials.h \
     sbr/ctype-checked.h \
+    sbr/datetime.h \
     sbr/discard.h \
     sbr/dtime.h \
     sbr/encode_rfc2047.h \
     sbr/discard.h \
     sbr/dtime.h \
     sbr/encode_rfc2047.h \
index 0bedfde..1f76921 100644 (file)
@@ -74,11 +74,6 @@ struct contentline *find_contentline (contentline *, const char *,
                                       const char *) PURE;
 void free_contentlines (contentline *);
 
                                       const char *) PURE;
 void free_contentlines (contentline *);
 
-typedef struct tzdesc *tzdesc_t;
-tzdesc_t load_timezones (const contentline *);
-void free_timezones (tzdesc_t);
-char *format_datetime (tzdesc_t, const contentline *);
-
 /*
  * The following provide access to, and by, the iCalendar parser.
  */
 /*
  * The following provide access to, and by, the iCalendar parser.
  */
index 71a21f9..3cbd171 100644 (file)
@@ -9,6 +9,7 @@
 #include "dtime.h"
 #include "error.h"
 #include "h/icalendar.h"
 #include "dtime.h"
 #include "error.h"
 #include "h/icalendar.h"
+#include "datetime.h"
 #include "h/fmt_scan.h"
 #include "h/tws.h"
 #include "h/utils.h"
 #include "h/fmt_scan.h"
 #include "h/tws.h"
 #include "h/utils.h"
diff --git a/sbr/datetime.h b/sbr/datetime.h
new file mode 100644 (file)
index 0000000..b525477
--- /dev/null
@@ -0,0 +1,11 @@
+/* datetime.h -- functions for manipulating RFC 5545 date-time values
+ *
+ * This code is Copyright (c) 2017, by the authors of nmh.
+ * See the COPYRIGHT file in the root directory of the nmh
+ * distribution for complete copyright information. */
+
+typedef struct tzdesc *tzdesc_t;
+
+tzdesc_t load_timezones(const contentline *);
+void free_timezones(tzdesc_t);
+char *format_datetime(tzdesc_t, const contentline *);
index d0ebd13..9618b2b 100644 (file)
@@ -15,6 +15,7 @@
 #include "sbr/print_help.h"
 #include "sbr/error.h"
 #include "h/icalendar.h"
 #include "sbr/print_help.h"
 #include "sbr/error.h"
 #include "h/icalendar.h"
+#include "sbr/datetime.h"
 #include "sbr/icalparse.h"
 #include "h/fmt_scan.h"
 #include "h/addrsbr.h"
 #include "sbr/icalparse.h"
 #include "h/fmt_scan.h"
 #include "h/addrsbr.h"