google / skicka

Command-line utility for working with Google Drive. Join the mailing list at https://groups.google.com/forum/#!forum/skicka-users.
Apache License 2.0
1.3k stars 118 forks source link

Close disk cache file immediately after use. Fixes #75 #80

Closed bgrainger closed 9 years ago

bgrainger commented 9 years ago

The defer f.Close call is still there, so this ends up closing the file twice (which doesn't appear to cause a problem).

Let me know if you think lines 622-657 should be extracted out to a separate method (so that defer will be sufficient); I couldn't decide if that would improve readability/maintainability or not.