file handle leak fix (#118)

unexpectedly it has nothing to do with webdav