Stratoscale / osmosis

Osmosis replaces rsync, where the backend is a git-like object store. Its used for storing build products (and rootfses)
Apache License 2.0
7 stars 16 forks source link

force file with bad state to be removed during checkout #8

Closed sashas-lb closed 8 years ago

sashas-lb commented 8 years ago

Hi osmosis maintainer, I had found the following issue in osmosis:

When removeUnknownFiles flag is specified during checkout stage, but file is in "bad state" (for example symlink that points to itself, which can be created with ln -s link link), [ this is just an example though i had encountered probably because of some file system errors] The thing is osmosis fails to complete checkout, it tries to check symlink istatus for examoke in boost::filesystem::symbolic_link_exists, and fails.

According to boost documentation this error state means that it was impossible to determine file attributes and whether file actually exists or not. In this case it is better to dispose this file,as it cannot be used anyhow. (see http://www.boost.org/doc/libs/1_44_0/libs/filesystem/v3/doc/reference.html#status).

eliran-stratoscale commented 8 years ago

Thanks!

sashas-lb commented 7 years ago

@eliran-stratoscale cool thanks