upload script now reports exit code of upload