diff options
| author | Michael Crosby | 2014-03-15 18:43:33 -0700 |
|---|---|---|
| committer | Michael Crosby | 2014-03-15 18:43:33 -0700 |
| commit | 47a1ed9678a401d63b06dae06a2105688c5a0f0b (patch) | |
| tree | cb24c7ffb7dc4cfcc5a09891622705ee676a58e4 /upload.sh | |
| parent | a91f723db326cbc17085b4ac4ab95afdd7a63754 (diff) | |
| download | gdrive-47a1ed9678a401d63b06dae06a2105688c5a0f0b.tar.bz2 | |
Return error from funcs so that defers are run
If you do an os.Exit from your functions any defer's that are
supposed to be run will not because the application gets terminated.
Defers only run when the function returns so it is better to return
the errs from your functions instead of aborting with an exit. This
patch also ensures that the error messages are printed on stderr and not
stdout. FYI, fmt.Print* writes to stdout while the log pkg writes to
stderr.
Diffstat (limited to 'upload.sh')
0 files changed, 0 insertions, 0 deletions
