Mercury Bugs - mercury | |||||
| View Issue Details | |||||
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0000265 | mercury | Bug | public | 2012-11-15 00:30 | 2012-12-07 05:44 |
| Reporter | gloomdemon | ||||
|---|---|---|---|---|---|
| Assigned To | |||||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | new | Resolution | open | ||
| Platform | windows | OS | windows 32/64 | OS Version | any |
| Product Version | |||||
| Target Version | Fixed in Version | ||||
| Summary | 0000265: long path handling in io module | ||||
| Description | "io.file_type" uses "_wstat" in C grade, but *stat didn't support long names on Windows OS (> 260) http://social.msdn.microsoft.com/Forums/en/vcgeneral/thread/3c093ea9-f0aa-446d-b648-2dabe8480430 It may be fixed by using "FindFirstFileW" with "\\?\" file name prefix instead of "_wstat". Also, other functions in io module (open_input -> mercury_open -> _wfopen) may be can't handle long path. | ||||
| Steps To Reproduce | unpack test_dir.tar, change path to unpacked directory in bugl program, compile and run | ||||
| Additional Information | :- module bugl. :- interface. :- import_module io. :- pred main(io::di, io::uo) is det. :- implementation. :- import_module require, dir, list, bool. main(!IO) :- Ps = ( pred(DN::in, BN::in, FT::in, C::out, Di::in, Do::out, !.IO::di, !:IO::uo) is det :- C = yes, io.write_strings([DN, " ", BN, "\n"], !IO), Do = Di ), dir.recursive_foldl2(Ps, "C:\\5", no, [], MaybeResult, !IO), ( MaybeResult = error(_, Err), error(io.error_message(Err)) % exception ; MaybeResult = ok(_) ). | ||||
| Tags | No tags attached. | ||||
| Relationships | |||||
| Attached Files | https://bugs.mercurylang.org/file_download.php?file_id=162&type=bug https://bugs.mercurylang.org/file_download.php?file_id=164&type=bug | ||||
| Notes | |||||
|
|
|||||
|
|
||||
| Issue History | |||||
| Date Modified | Username | Field | Change | ||
|---|---|---|---|---|---|
| 2012-11-15 00:30 | gloomdemon | New Issue | |||
| 2012-11-15 00:30 | gloomdemon | File Added: test_dir.tar | |||
| 2012-12-07 05:44 | gloomdemon | Note Added: 0000481 | |||
| 2012-12-07 05:44 | gloomdemon | File Added: dir.diff | |||
| 2012-12-07 05:45 | gloomdemon | Note Edited: 0000481 | bug_revision_view_page.php?bugnote_id=481#r9 | ||
| 2012-12-07 05:54 | gloomdemon | Note Edited: 0000481 | bug_revision_view_page.php?bugnote_id=481#r10 | ||