fix race in open of chunked files