Is boost::filesystem::path unable to deal with hidden unix dircetories?
Dear boost users and developers, I just encountered a minor problem in boost::filesystem::path which seems to be unable to deal with hidden unix directories ( == names preceeded by an dot '.' character ). Is there any way to generate a valid path object for paths like "/foo/.bar"? Trying to create such an object from a C++ string results in an exception getting thrown. ------------------------------------------------------------------------------------- Dipl.-Inform. Hendrik Belitz Central Institute of Electronics / Zentralinstitut für Elektronik Multimodal image processing workgroup / AG Multimodale Bildverarbeitung Research Center Juelich / Forschungszentrum Jülich GmbH D-52428 Jülich, Germany Tel.: (++49)2461 61 8701 Fax: (++49)2461 61 3990 email: h.belitz@fz-juelich.de ggp-key available via http://pgpkeys.pca.dfn.de
Hi, You can perhaps create your path without the name check. (use name_checker no_name_check in the constructor or something like this). Alexandre Gacon -----Message d'origine----- De : boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] De la part de Hendrik Belitz Envoyé : lundi 9 janvier 2006 10:39 À : boost-users@lists.boost.org Objet : [Boost-users] Is boost::filesystem::path unable to deal with hiddenunix dircetories? Dear boost users and developers, I just encountered a minor problem in boost::filesystem::path which seems to be unable to deal with hidden unix directories ( == names preceeded by an dot '.' character ). Is there any way to generate a valid path object for paths like "/foo/.bar"? Trying to create such an object from a C++ string results in an exception getting thrown. ---------------------------------------------------------------------------- --------- Dipl.-Inform. Hendrik Belitz Central Institute of Electronics / Zentralinstitut für Elektronik Multimodal image processing workgroup / AG Multimodale Bildverarbeitung Research Center Juelich / Forschungszentrum Jülich GmbH D-52428 Jülich, Germany Tel.: (++49)2461 61 8701 Fax: (++49)2461 61 3990 email: h.belitz@fz-juelich.de ggp-key available via http://pgpkeys.pca.dfn.de
On 09/01/06, Hendrik Belitz
I just encountered a minor problem in boost::filesystem::path which seems to be unable to deal with hidden unix directories ( == names preceeded by an dot '.' character ). Is there any way to generate a valid path object for paths like "/foo/.bar"? Trying to create such an object from a C++ string results in an exception getting thrown.
How are you creating said path? IIRC, the default name checker won't allow filenames whose leaves start with dots for portability reasons ( some OSes don't like them ). - Scott
participants (3)
-
Alexandre Gacon
-
Hendrik Belitz
-
me22