symbolic link from device name?

All:
What’s the best method of obtaining a device’s symbolic link from
within a driver? Example: I have “\device\harddiskvolume1” and I need
“C:”. The point in the code where I need it I have the device object so I
have the device name, … but not the symbolic link. I realize that
there isn’t necessarly a 1-1 relationship between symbolic links and
aliases so that may be an issue. I tried using IoGetDeviceInterfaces but
am blue screening…

Any help is appreciated.

Thanks,

Chuck

Try using “RtlVolumeDeviceToDosName” (in XP & later it is called
IoVolumeDeviceToDosName though the old name is still exported for now).

I would recommend you retrieve this once and store it in you device
extension.

Neal Christiansen
Microsoft File System Filter Group

This posting is provided “AS IS” with no warranties, and confers no
rights.

-----Original Message-----
From: chuck m [mailto:chuck.monarch@hp.com]
Sent: Monday, March 24, 2003 3:24 PM
To: File Systems Developers

All:
What’s the best method of obtaining a device’s symbolic link from
within a driver? Example: I have “\device\harddiskvolume1” and I need
“C:”. The point in the code where I need it I have the device object so
I
have the device name, … but not the symbolic link. I realize that
there isn’t necessarly a 1-1 relationship between symbolic links and
aliases so that may be an issue. I tried using IoGetDeviceInterfaces but
am blue screening…

Any help is appreciated.

Thanks,

Chuck


You are currently subscribed to ntfsd as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com