fix file unlinking