summaryrefslogtreecommitdiffstats
path: root/TOOLS
diff options
context:
space:
mode:
authorJames Ross-Gowan <rossymiles@gmail.com>2014-04-09 18:14:18 +1000
committerwm4 <wm4@nowhere>2014-04-09 20:41:51 +0200
commit17d0609d1e8c36d70b5994e779a364f6df429937 (patch)
tree78928bcbbef2ce9e660d8f2a1f4df4d0ce77c994 /TOOLS
parent217008be4a821d91f2651f9506321327d8f551bf (diff)
downloadmpv-17d0609d1e8c36d70b5994e779a364f6df429937.tar.bz2
mpv-17d0609d1e8c36d70b5994e779a364f6df429937.tar.xz
stream_file: Check the handle for network streams
Use NtQueryVolumeInformationFile instead of GetDriveType for detecting remote filesystems on Windows. This has the advantage of working directly on the file handle instead of needing a path and it works unmodified in Cygwin where the previous code wouldn't understand Cygwin paths or symlinks. There is some risk in using NtQueryVolumeInformationFile, since it's an internal function and its behaviour could change at any time or it could be removed in a future version of Windows, however it's documented[1] in the WDK and it's used successfully by Cygwin, so it should be fine. If it's removed, the code should fail gracefully by treating all files as local. [1]: http://msdn.microsoft.com/en-us/library/windows/hardware/ff567070.aspx Signed-off-by: wm4 <wm4@nowhere>
Diffstat (limited to 'TOOLS')
0 files changed, 0 insertions, 0 deletions