summaryrefslogtreecommitdiff
path: root/x11/xphoon/patches/patch-ad
blob: 32e7bc1bf1d0705eb7869cf1ec15f245d6bf030e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
$NetBSD: patch-ad,v 1.1 2008/07/28 02:45:56 dholland Exp $

--- tws.h.orig	1991-09-13 19:32:38.000000000 -0400
+++ tws.h	2008-07-27 22:31:10.000000000 -0400
@@ -1,5 +1,6 @@
 /* tws.h - header file for libtws date/time library */
 
+#include <time.h>
 
 /* Definition of the tws data structure. */
 
@@ -17,7 +18,7 @@ struct tws {
 
     int     tw_zone;
 
-    long    tw_clock;
+    time_t  tw_clock;
 
     int     tw_flags;
 #define TW_NULL 0x0000
@@ -33,47 +34,9 @@ struct tws {
 
 /* Declarations of routines. */
 
-void twscopy( );
-	/* twscopy( &totws, &fromtws ) copies a tws */
-int twsort( );
-	/* twsort( &tws1, &tws2 ) compares two tws's: 1 means tws1 is
-	   later; -1 means tws1 is earlier; 0 means they are equal */
-long twclock( );
-	/* twclock( &tws ) turns a tws into a time(3)-style clock value */
-long twjuliandate( );
-	/* twjuliandate( &tws ) returns the Julian day number of a tws */
-long twsubtract( );
-	/* twsubtract( &tws1, &tws2 ) returns seconds of difference */
-
-/* These routines are functionally similar to the ctime(3) routines
-   in the standard Unix library. */
-char *dctime( );
-	/* dctime( &tws ) returns a string for the date/time passed in */
-struct tws *dlocaltime( );
+struct tws *dlocaltime(time_t *clock);
 	/* dlocaltime( &clock ) turns a time(3) clock value into a tws */
-struct tws *dgmtime( );
-	/* dgmtime( &clock ) turns a time(3) clock value into a tws */
-char *dasctime( );
-	/* dasctime( &tws, flags ) turns a tws into a string */
-char *dtimezone( );
-	/* dtimezone( offset, flags ) returns the name of the time zone */
 
-char *dtimenow( );
-	/* dtimenow( ) returns a string for the current date/time */
-
-struct tws *dparsetime( );
-	/* dparsetime( &str ) turns a string into a tws */
-
-struct tws *dtwstime( );
+struct tws *dtwstime(void);
 	/* dtwstime( ) returns a tws for the current date/time */
 
-#ifdef ATZ
-#define dtime(cl) dasctime( dlocaltime( cl ), TW_NULL )
-#else ATZ
-#define dtime(cl) dasctime( dlocaltime( cl ), TW_ZONE )
-#endif ATZ
-
-#define dtwszone(tw) dtimezone( tw -> tw_zone, tw -> tw_flags )
-
-
-extern char   *tw_dotw[], *tw_ldotw[], *tw_moty[];