[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short fi
From: |
Markus Mützel |
Subject: |
[Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names |
Date: |
Sat, 8 May 2021 13:56:17 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.93 Safari/537.36 Edg/90.0.818.51 |
Follow-up Comment #6, bug #60554 (project octave):
Good point. I pushed similar changes for those classes here:
https://hg.savannah.gnu.org/hgweb/octave/rev/161daebce243
However, I don't think we should rely on short file names at all to solve bugs
with spaces in paths. They are an optional feature in NTFS file systems. And
more and more PC/Laptop manufactures (like Dell) seem to disable that feature
in the devices they sell. See e.g.:
https://octave.discourse.group/t/help-with-mkoctfile/1122
Imho, we should resolve issues with spaces in paths by correctly quoting those
paths in the affected commands. This is (partly?) done for mkoctfile in Octave
7.
I think we should use the paths as they are (and not manipulate them by
default) unless we know we need it in a certain form like in the case here.
Maybe there are functions in the C++17 filesystem API that make checking if a
file is in a subdirectory of a given path easier.
Maybe this?
https://en.cppreference.com/w/cpp/filesystem/relative
In any case, since we are using C++11 currently, I believe the approach with
canonicalizing the paths and comparing strings works "good enough" for now.
And since we can use static variables here, there shouldn't be any noticeable
performance impact.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?60554>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #60554] Octave default paths stored as short names, anonymous, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file doesn short names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, anonymous, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, anonymous, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names,
Markus Mützel <=
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/08
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/10
- [Octave-bug-tracker] [bug #60554] is_system_fcn_file fails with short file names, Markus Mützel, 2021/05/13