Enrico Forestieri wrote:

> Been there, done that. The attached would be the patch you are looking
> for, but it only fixes the assertion, not the other bug I mention.
> This is because fileSearch is designed to replace an extension, not to
> add one.

I don't think that was intended. I rather think that the problem is that
changeExtension does not really know if a file has no extension. Maybe we
should introduce aan addExtension and use that if we know that a filename
has no extension?

> Of course, it would be possible to modify fileSearch such that 
> it adds the extension when must_be_readable is false, but I find this
> approach rather ugly.

I agree. Nevertheless I like your second patch much more, because it makes
the intention clear. In a second step we can introduce addExtension() and
use that in fileSearch.


Georg

Reply via email to