Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

AbsolutePath.ReadKind reports volume mount points (mounted folders) as junctions

Đang mở
#253 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 5 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
48/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
csharp
Lĩnh vực
backend

Hướng nghiên cứu

Start with AbsolutePath.ReadKind() in TruePath/AbsolutePath.cs and DiskUtils.IsJunction in TruePath/DiskUtils.cs, then review issue #242 for the related reparse buffer parsing work. Reproduce with a Windows volume mount point and inspect how its SubstituteName differs from a directory junction. Done means volume mount points are classified according to the chosen FileEntryKind behavior while directory junctions keep their existing classification.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug help wanted

On Windows, AbsolutePath.ReadKind() returns FileEntryKind.Junction whenever DiskUtils.IsJunction sees the reparse tag IO_REPARSE_TAG_MOUNT_POINT.

But NTFS uses that same tag for two different things:

  • directory junctions, where the target is a directory path, e.g. \??\C:\Some\Dir;
  • volume mount points ("mounted folders", created via Disk Management or mountvol), where the target is a volume, e.g. \??\Volume{GUID}\.

See Reparse Point Tags and Creating Mounted Folders.

So a folder with a whole volume mounted on it is reported as a Junction, although it's not a link to another directory: it's the root of another file system.

Repro (requires an elevated shell and a spare volume, e.g. a VHD):

mkdir C:\Mnt
mountvol C:\Mnt \\?\Volume{<guid>}\   # take the GUID from `mountvol` output
new AbsolutePath(@"C:\Mnt").ReadKind(); // FileEntryKind.Junction

Recommendations

  • Tell the two apart by the SubstituteName in the MountPointReparseBuffer. A volume mount point's target starts with \??\Volume{.
  • Decide what a volume mount point should be reported as. FileEntryKind.Directory needs no API change. A new FileEntryKind.MountPoint value is more precise, but it is a public API addition.
  • This needs tag-specific parsing of the reparse buffer, which ties in with #242.
Ngôn ngữ chính
C#
Star
109
Fork
26
Merge trung bình
5 ngày 23 phút
Pull request đã merge (30 ngày)
10

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của ForNeVeR/TruePath

Tất cả issue của ForNeVeR/TruePath

Issue tương tự

Thêm issue về C#

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.