boost filesystem question

Hello all,
I am trying to use the "path" and "copy_file" functions of boost filesystem in C++, and they work fine, except for cases when there are hidden files or subdirectory as below:

for example, if I have the following directory pattern (Dir1 is the parent directory, and the rest are the child files/subdirectories):

Dir1
file1
file2
.file3
subdir1
.subdir2

the following code will go through the Dir1, and it will fails in creating the "path" when it reaches ".file3" or ".subdir2"

boost::filesystem::path dir1_path(filepath.c_str());
if( !boost::filesystem::exists(dir1_path) )
cout<<"\nFile Not Found:" <<"\n";
boost::filesystem::copy_file(filepath.c_str(), dir2_path);

It is very common to have subdirectories inside directories that start with "." (in Windows platform these are the hidden files), any suggestion as far as how to copy a file that starts with character "." ?

I would appreciate some help.

thanks in advance,
Rudy

You might want to ask this question in the Boost mailing list/forum (I forget what they use, at the moment). As far as I know, though, there shouldn't be any problems handling UNIX-hidden files.
Topic archived. No new replies allowed.