:pserver:cvsanon@mok.lvcm.com:/CVS/ReactOS reactos
[reactos.git] / lib / crtdll / direct / getdrive.c
1 #include <crtdll/direct.h>
2 #include <crtdll/ctype.h>
3 #include <windows.h>
4
5 extern int cur_drive;
6
7
8
9 int _getdrive( void )
10 {
11         char Buffer[MAX_PATH];
12
13         if ( cur_drive == 0 ) {
14                 GetCurrentDirectoryA(MAX_PATH,Buffer);
15                 cur_drive = toupper(Buffer[0] - '@');
16         }
17         
18         return cur_drive;
19 }
20
21 unsigned long _getdrives(void)
22 {
23     //fixme get logical drives
24     //return GetLogicalDrives();
25      return 5;  // drive A and C
26 }