Boost logo

Boost :

From: David Daeschler (daveregs_at_[hidden])
Date: 2005-05-25 14:14:02


>From my application there may come a time when I want to take a directory or
file name from a user. In windows, there is a file selection box that can
return the full path of a file that the user chooses. The full path in
windows includes the drive name with a colon and then a backslash ( c:\ ).
I can not seem to get the boost filesystem library to accept this as a valid
path even with the native checker. I also ran the test provided with boost
for paths and it failed. The output is given below.

$ bfs
Platform is Windows
initial_path().string() is
initial_path().native_file_string() is
d:/srcbuilds/boost_1_32_0/boost/test/minimal.hpp(129): exception
: boost::filesystem::path: invalid name "c:" in path: "c:/"" caught in
 'int main(int, char**)'

**** Testing aborted.
**** 1 error detected

It appears that the colon is in the list of invalid characters for a file
and it is throwing things off.

My version of Boost was compiled with MinGW under Windows XP SP2 using the
command line bjam "-sTOOLS=mingw" stage

If I am missing something please let me know.

Thank you for your time,
- Dave

Boost list run by bdawes at, gregod at, cpdaniel at, john at