this should probably be in a try/finally block in case there's an error during extraction, so we guarantee the file will be closed.