函数名: dostounix
功 能: 转换日期和时间为UNIX时间格式
用 法: #include <dos.h>
long dostounix(struct date *dateptr, struct time *timeptr);
程序例:
#include <time.h>
#include <stddef.h>
#include <dos.h>
#include <stdio.h>
int main(void)
{
time_t t;
struct time d_time;
struct date d_date;
struct tm *local;
getdate(&d_date);
gettime(&d_time);
t = dostounix(&d_date, &d_time);
local = localtime(&t);
printf("Time and Date: %s\n", \
asctime(local));
return 0;
}