From 14042f631de03b0b6730fb8fdb89e7abc8202f4a Mon Sep 17 00:00:00 2001 From: "Andrew A. de Laix" Date: Mon, 24 Jan 2011 10:54:08 -0800 Subject: fix CHOP-369: catch case of synchronous download failure. --- indra/viewer_components/updater/llupdaterservice.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'indra/viewer_components/updater') diff --git a/indra/viewer_components/updater/llupdaterservice.cpp b/indra/viewer_components/updater/llupdaterservice.cpp index ea242f45cd..20534fdf3a 100644 --- a/indra/viewer_components/updater/llupdaterservice.cpp +++ b/indra/viewer_components/updater/llupdaterservice.cpp @@ -375,7 +375,11 @@ void LLUpdaterServiceImpl::optionalUpdate(std::string const & newVersion, mIsDownloading = true; mUpdateDownloader.download(uri, hash, newVersion, false); - setState(LLUpdaterService::DOWNLOADING); + if(getState() != LLUpdaterService::FAILURE) { + setState(LLUpdaterService::DOWNLOADING); + } else { + ; // Download failed snynchronously; we are done. + } } void LLUpdaterServiceImpl::requiredUpdate(std::string const & newVersion, @@ -387,7 +391,11 @@ void LLUpdaterServiceImpl::requiredUpdate(std::string const & newVersion, mIsDownloading = true; mUpdateDownloader.download(uri, hash, newVersion, true); - setState(LLUpdaterService::DOWNLOADING); + if(getState() != LLUpdaterService::FAILURE) { + setState(LLUpdaterService::DOWNLOADING); + } else { + ; // Download failed snynchronously; we are done. + } } void LLUpdaterServiceImpl::upToDate(void) -- cgit v1.2.3 From 9fa947ef741f6e63be1994e83fcf8f182e7eebed Mon Sep 17 00:00:00 2001 From: "Andrew A. de Laix" Date: Mon, 24 Jan 2011 14:58:10 -0800 Subject: a less brain dead fix for CHOP-369 --- indra/viewer_components/updater/llupdaterservice.cpp | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) (limited to 'indra/viewer_components/updater') diff --git a/indra/viewer_components/updater/llupdaterservice.cpp b/indra/viewer_components/updater/llupdaterservice.cpp index 20534fdf3a..1888f191e2 100644 --- a/indra/viewer_components/updater/llupdaterservice.cpp +++ b/indra/viewer_components/updater/llupdaterservice.cpp @@ -373,13 +373,8 @@ void LLUpdaterServiceImpl::optionalUpdate(std::string const & newVersion, stopTimer(); mNewVersion = newVersion; mIsDownloading = true; + setState(LLUpdaterService::DOWNLOADING); mUpdateDownloader.download(uri, hash, newVersion, false); - - if(getState() != LLUpdaterService::FAILURE) { - setState(LLUpdaterService::DOWNLOADING); - } else { - ; // Download failed snynchronously; we are done. - } } void LLUpdaterServiceImpl::requiredUpdate(std::string const & newVersion, @@ -389,13 +384,8 @@ void LLUpdaterServiceImpl::requiredUpdate(std::string const & newVersion, stopTimer(); mNewVersion = newVersion; mIsDownloading = true; + setState(LLUpdaterService::DOWNLOADING); mUpdateDownloader.download(uri, hash, newVersion, true); - - if(getState() != LLUpdaterService::FAILURE) { - setState(LLUpdaterService::DOWNLOADING); - } else { - ; // Download failed snynchronously; we are done. - } } void LLUpdaterServiceImpl::upToDate(void) -- cgit v1.2.3