2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these librararies and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
23 /*******************************************************************************
27 ** static char sccsid[] = "@(#)getdate.h 1.6 94/11/07 Copyr 1991 Sun Microsystems, Inc.";
29 ** $XConsortium: getdate.h /main/3 1995/11/03 10:37:54 rswiston $
31 ** RESTRICTED CONFIDENTIAL INFORMATION:
33 ** The information in this document is subject to special
34 ** restrictions in a confidential disclosure agreement between
35 ** HP, IBM, Sun, USL, SCO and Univel. Do not distribute this
36 ** document outside HP, IBM, Sun, USL, SCO, or Univel without
37 ** Sun's specific written approval. This document and all copies
38 ** and derivative works thereof must be returned or destroyed at
41 ** Copyright 1993 Sun Microsystems, Inc. All rights reserved.
43 *******************************************************************************/
46 * (c) Copyright 1993, 1994 Hewlett-Packard Company *
47 * (c) Copyright 1993, 1994 International Business Machines Corp. *
48 * (c) Copyright 1993, 1994 Sun Microsystems, Inc. *
49 * (c) Copyright 1993, 1994 Novell, Inc. *
55 #if defined(USG) || defined(__OpenBSD__)
59 unsigned short millitm;
64 #include <sys/timeb.h>
71 #define DATE_PARSE -1 /* date simply did not parse */
72 #define DATE_BBOT -2 /* date was before beginning of time */
73 #define DATE_AEOT -3 /* date was after end of time */
74 #define DATE_BMONTH -4 /* date had a bad month number */
75 #define DATE_BDAY -5 /* date had a bad day number */
76 #define DATE_BMIN -6 /* date had a bad minute number */
77 #define DATE_BHOUR -7 /* date had a bad hour number */
78 #define DATE_CONV -8 /* date converted poorly for am/pm/24hr */
80 extern time_t dateconv P((int, int, int, int, int, int, int, int, int));
81 extern time_t dayconv P((int, int, time_t));
82 extern time_t timeconv P((int, int, int, int));
83 extern time_t monthadd P((time_t, time_t));
84 extern time_t daylcorr P((time_t, time_t));
85 extern time_t cm_getdate P((char*, struct timeb *));