Optimized some leftover filesaving/loading techniques (closing streams)