Made upload calls blocking.  Added error checking during upload.