This call returns the full path name of the current directory for the requesting process for the specified drive.
DosQCurDir
DriveNumber (USHORT) - input
Value
The drive letter is not part of the returned string. The string does not begin with a backslash and is terminated by a byte containing 00H.
The system returns the length of the returned DirPath string in DirPathLen, which does not include the terminating null byte. In the case where the DirPath buffer is of insufficient length to hold the current directory path string, the system returns the required length (in bytes) for DirPath in DirPathLen.
For FSDs, the case of the current directory is set according to the DirName passed in, not according to the case of the directories on disk. For example, if the directory "c:\bin" is created and DosChDir is called with DirName "c:\bin", the current directory returned by DosQCurDir will be "c:\bin".
Programs running without the NEWFILES bit set are allowed to DosChDir to a non-8.3 filename format directory.
DosQSysInfo must be used by an application to determine the maximum path length supported by OS/2. The returned value should be used to dynamically allocate buffers that are to be used to store paths.