newlib-cygwin/newlib/libc/sys/go32/getdate.c

12 lines
219 B
C
Raw Normal View History

2000-02-18 03:39:52 +08:00
#include "dos.h"
void getdate( struct date *dateblk)
{
union REGS regs;
regs.h.ah = 0x2a;
intdos( &regs, &regs);
dateblk-> da_year = regs.x.cx;
dateblk-> da_mon = regs.h.dh;
dateblk-> da_day = regs.h.dl;
}