home *** CD-ROM | disk | FTP | other *** search
- #include <jaz.h>
- /*
- ┌────────────────────────────────────────────────────────────────────────────┐
- │jzgetdr │
- │get the current working sub-directory │
- │Synopsis: │
- │ jzgetdr(wdirectory); │
- │ │
- └────────────────────────────────────────────────────────────────────────────┘
- */
-
- jzgetdr(fdir)
- char *fdir;
- {
- TREG wreg;
-
- wreg.h.ah = 0x47;
- wreg.x.ds = getds();
- wreg.x.si = (int) fdir;
- wreg.h.dl = 0; /* default directory */
-
- msdos(&wreg);
-
- if (wreg.x.flags & 1)
- *fdir = 0;
- }