|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T t
Length: 1122 (0x462)
Types: TextFile
Names: »tm2ut.c«
└─⟦3d0c2be1b⟧ Bits:30001254 ISODE-5.0 Tape
└─⟦eba4602b1⟧ »./isode-5.0.tar.Z«
└─⟦d3ac74d73⟧
└─⟦this⟧ »isode-5.0/psap/tm2ut.c«
/* tm2ut.c - tm to time string */
#ifndef lint
static char *rcsid = "$Header: /f/osi/psap/RCS/tm2ut.c,v 6.0 89/03/18 23:39:36 mrose Rel $";
#endif
/*
* $Header: /f/osi/psap/RCS/tm2ut.c,v 6.0 89/03/18 23:39:36 mrose Rel $
*
*
* $Log: tm2ut.c,v $
* Revision 6.0 89/03/18 23:39:36 mrose
* Release 5.0
*
*/
/*
* NOTICE
*
* Acquisition, use, and distribution of this module and related
* materials are subject to the restrictions of a license agreement.
* Consult the Preface in the User's Manual for the full terms of
* this agreement.
*
*/
/* LINTLIBRARY */
#include <stdio.h>
#include "psap.h"
#ifdef OSX
#include <sys/time.h>
#endif
#define YEAR(y) ((y) >= 100 ? (y) : (y) + 1900)
/* \f
*/
void tm2ut (tm, ut)
register struct tm *tm;
register UTC ut;
{
bzero ((char *) ut, sizeof *ut);
ut -> ut_year = YEAR (tm -> tm_year);
ut -> ut_mon = tm -> tm_mon + 1;
ut -> ut_mday = tm -> tm_mday;
ut -> ut_hour = tm -> tm_hour;
ut -> ut_min = tm -> tm_min;
ut -> ut_sec = tm -> tm_sec;
ut -> ut_zone = 0;
ut -> ut_flags = UT_ZONE | UT_SEC;
}