Fixed some bugs in File cache and other files.