Release 960225
[wine] / include / dos_fs.h
1 /*
2  * DOS file system declarations
3  *
4  * Copyright 1996 Alexandre Julliard
5  */
6
7 #ifndef __WINE_DOS_FS_H
8 #define __WINE_DOS_FS_H
9
10 #include <time.h>
11 #include "wintypes.h"
12
13 #define MAX_FILENAME_LEN   256
14 #define MAX_PATHNAME_LEN   1024
15
16 typedef struct
17 {
18     char   name[12];                    /* File name in FCB format */
19     char   unixname[MAX_FILENAME_LEN];  /* Unix file name */
20     DWORD  size;                        /* File size in bytes */
21     WORD   date;                        /* File date in DOS format */
22     WORD   time;                        /* File time in DOS format */
23     BYTE   attr;                        /* File DOS attributes */
24 } DOS_DIRENT;
25
26 #define IS_END_OF_NAME(ch)  (!(ch) || ((ch) == '/') || ((ch) == '\\'))
27
28 extern void DOSFS_ToDosDateTime( time_t *unixtime, WORD *pDate, WORD *pTime );
29 extern const char *DOSFS_ToDosFCBFormat( const char *name );
30 extern const char *DOSFS_ToDosDTAFormat( const char *name );
31 extern const char *DOSFS_IsDevice( const char *name );
32 extern const char * DOSFS_GetUnixFileName( const char * name, int check_last );
33 extern const char * DOSFS_GetDosTrueName( const char *name, int unix_format );
34 extern int DOSFS_GetDosFileName( const char *name, char *buffer, int len );
35 extern int DOSFS_FindNext( const char *path, const char *mask, int drive,
36                            BYTE attr, int skip, DOS_DIRENT *entry );
37
38
39 extern int DOS_GetFreeSpace(int drive, long *size, long *available);
40 extern char *WineIniFileName(void);
41
42 #endif /* __WINE_DOS_FS_H */