small file opening validation added