Handled exceptions if SFTP and SSH objects were not initialized correctly.  Also restored chan_wait temp to append data from what it receives on the channel, instead of just check 1k of data at a time