*** empty log message ***

svn path=/trunk/boinc/; revision=3498
This commit is contained in:
Daniel Hsu 2004-06-03 21:19:18 +00:00
parent 3c964e41fb
commit d0c11718ae
3 changed files with 17 additions and 2 deletions

View File

@ -12984,3 +12984,15 @@ David June 2 2004
api/ api/
boinc_api.C 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

View File

@ -204,7 +204,8 @@ bool CLIENT_STATE::handle_pers_file_xfers() {
fip->delete_file(); fip->delete_file();
} }
fip->uploaded = true; 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 // verify the file with RSA or MD5, and change permissions
// //

View File

@ -128,17 +128,19 @@ int PERS_FILE_XFER::start_xfer() {
} else { } else {
retval = file_xfer->init_download(*fip); retval = file_xfer->init_download(*fip);
} }
fxp = file_xfer;
if (retval) { if (retval) {
msg_printf( msg_printf(
fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d", fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d",
(is_upload ? "upload" : "download"), fip->get_url(), retval (is_upload ? "upload" : "download"), fip->get_url(), retval
); );
handle_xfer_failure(); handle_xfer_failure();
delete fxp;
fxp = NULL;
return retval; return retval;
// TODO: do we need to do anything here? // TODO: do we need to do anything here?
} }
retval = gstate.file_xfers->insert(file_xfer); retval = gstate.file_xfers->insert(file_xfer);
fxp = file_xfer;
if (retval) { if (retval) {
msg_printf( msg_printf(
fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d", fip->project, MSG_ERROR, "Couldn't start %s for %s: error %d",