Dear P.O Having extra separators does not make a path invalid
Just try with playing around with ls Just checked ls ////opt/////ooRexx/bin///rexx ls ////opt/////ooRexx/bin///// E > On 7 Feb 2019, at 11:09, P.O. Jonsson <oor...@jonases.se> wrote: > > Dear Developers, > > When working on modifying FileUtils.cls to work also for macOS/Darwin I used > (by mistake, certainly) SysFileTree() with an invalid path and was astonished > to see that it nevertheless produced a valid result. Is this intended? > > This is what I intended to do: > > installDir = '/Users/po/Applications/ooRexx5.0.0‘ > name = 'rexx' > j = SysFileTree(installDir'/bin/'name, f., 'FOS') > > But instead I did (note the trailing slash) > > installDir = '/Users/po/Applications/ooRexx5.0.0/‘ > name = 'rexx' > j = SysFileTree(installDir'/bin/'name, f., 'FOS') > > This produces a „//„ in the path, i.e. an illegal path > > Nevertheless SysFileTree() „corrected“ my input path, removed the additional > slash and gave me the correct path back as f.1. > > I also tried on Windows and there SysFileTree() considers a path with double > backslash to be correct (return value 0), but the output is not corrected as > on MAC. > > I have attached two scripts to show the behavior , amend to fit your > installation and have a try. I did not investigate on Linux/Unix. > > <Mactest.rex> > <Wintest.rex> > > Hälsningar/Regards/Grüsse, > P.O. Jonsson > oor...@jonases.se <mailto:oor...@jonases.se> > > > > > _______________________________________________ > Oorexx-devel mailing list > Oorexx-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/oorexx-devel
_______________________________________________ Oorexx-devel mailing list Oorexx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/oorexx-devel