Boost logo

Boost Users :

Subject: Re: [Boost-users] filesystem::recursive_directory_iterator quits on unreadable directory
From: Ravi (lists_ravi_at_[hidden])
Date: 2008-10-06 09:39:01


On Thursday 02 October 2008 16:42:24 Charles Karney wrote:
> The increment operator in filesystem::recursive_directory_iterator
> throws an exception when trying to enter an unreadable directory
> (permissions, no-such-device, etc.).  Often (usually?), a user wants to
> be able to skip the unreadable directory and continue the iteration over
> the rest of the directory tree.
>
> Catching this exception doesn't help because the iterator hasn't been
> incremented and I couldn't figure a way to skip over the unreadble
> directory.

Could you please file a trac item for this? The patch that you have proposed
does not seem right; the user might wish to be informed. Perhaps the right
approach is to throw the exception but ensure that the user can still skip
over the unreadable directory after catching the exception.

Regards,
Ravi


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net