Unload ofile before linking (Fix #10216)

Use an unlinked original file object (i.e. a proxy) for
linking the stdout and stderr. The files were previously
being uploaded, just linked. This is likely a result of
the files being modified on save to calculate the sha1,
but is not directly an FS issue.
Merge pull request #754 from joshmoore/10216-files

Unload ofile before linking (Fix #10216)