Close opened files