diff --git a/checkin_notes b/checkin_notes index 7fe0839fae..3f6e92a6a0 100755 --- a/checkin_notes +++ b/checkin_notes @@ -12984,3 +12984,15 @@ David June 2 2004 api/ boinc_api.C + +Daniel June 3 2004 + - client: handle_pers_file_xfers(): if file transfer fails, + then don't verify the file + - client: start_xfer(): need to assign fxp in order for + handle_xfer_failure() to work + + client/ + cs_files.C + pers_file_xfer.C + + diff --git a/client/cs_files.C b/client/cs_files.C index fd54a7180c..16c2644eb1 100644 --- a/client/cs_files.C +++ b/client/cs_files.C @@ -204,7 +204,8 @@ bool CLIENT_STATE::handle_pers_file_xfers() { fip->delete_file(); } fip->uploaded = true; - } else { + } else if (fip->status >= 0) { + // file transfer did not fail (non-negative status) // verify the file with RSA or MD5, and change permissions // diff --git a/client/pers_file_xfer.C b/client/pers_file_xfer.C index 7b9641a247..91ee661d32 100644 --- a/client/pers_file_xfer.C +++ b/client/pers_file_xfer.C @@ -128,17 +128,19 @@ int PERS_FILE_XFER::start_xfer() { } else { retval = file_xfer->init_download(*fip); } + fxp = file_xfer; if (retval) { msg_printf( fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d", (is_upload ? "upload" : "download"), fip->get_url(), retval ); handle_xfer_failure(); + delete fxp; + fxp = NULL; return retval; // TODO: do we need to do anything here? } retval = gstate.file_xfers->insert(file_xfer); - fxp = file_xfer; if (retval) { msg_printf( fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d",