Opened 10 years ago
Last modified 5 years ago
#8301 new Bugs
filesystem::canonical() has a race condition on Windows 7/10
Reported by: | y.hoshizuki | Owned by: | Beman Dawes |
---|---|---|---|
Milestone: | To Be Determined | Component: | filesystem |
Version: | Boost 1.59.0 | Severity: | Problem |
Keywords: | Cc: |
Description
read_symlink() often throws a exception.
to confirm this problem, please compile and run the attached file.
i think it caused by read_symlink() opening a file exclusively.
handle_wrapper h( create_file_handle(p.c_str(), GENERIC_READ, 0, 0, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS | FILE_FLAG_OPEN_REPARSE_POINT, 0));
FILE_SHARE_READ argument resolves this problem, isn't it?
Attachments (1)
Change History (2)
by , 10 years ago
Attachment: | canonical.cpp added |
---|
comment:1 by , 5 years ago
Summary: | filesystem::canonical() has a race condition on Windows 7 → filesystem::canonical() has a race condition on Windows 7/10 |
---|---|
Version: | Boost 1.51.0 → Boost 1.59.0 |
We found the same ....
Note:
See TracTickets
for help on using tickets.
test program