summaryrefslogtreecommitdiff
path: root/indra/viewer_components/updater/llupdaterservice.cpp
diff options
context:
space:
mode:
authorAndrew A. de Laix <alain@lindenlab.com>2010-12-16 09:34:19 -0800
committerAndrew A. de Laix <alain@lindenlab.com>2010-12-16 09:34:19 -0800
commit1774489ef8c224359e39d6281497e5128b043d24 (patch)
treece5ed7ab9092d2f6aa8cc9cb4080f22c71827a8f /indra/viewer_components/updater/llupdaterservice.cpp
parent6f996302ef5f8277dbfab9a75a536b554d7fa4e9 (diff)
Vary install failed message depending on whether it was required or not.
Diffstat (limited to 'indra/viewer_components/updater/llupdaterservice.cpp')
-rw-r--r--indra/viewer_components/updater/llupdaterservice.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/viewer_components/updater/llupdaterservice.cpp b/indra/viewer_components/updater/llupdaterservice.cpp
index df1a963f81..08f76c26e9 100644
--- a/indra/viewer_components/updater/llupdaterservice.cpp
+++ b/indra/viewer_components/updater/llupdaterservice.cpp
@@ -305,6 +305,7 @@ bool LLUpdaterServiceImpl::checkForInstall(bool launchInstaller)
int result = ll_install_update(install_script_path(),
update_info["path"].asString(),
+ update_info["required"].asBoolean(),
install_script_mode());
if((result == 0) && mAppExitCallback)
@@ -489,6 +490,12 @@ bool LLUpdaterServiceImpl::onMainLoop(LLSD const & event)
// Check for failed install.
if(LLFile::isfile(ll_install_failed_marker_path()))
{
+ int requiredValue = 0;
+ {
+ llifstream stream(ll_install_failed_marker_path());
+ stream >> requiredValue;
+ if(!stream) requiredValue = 0;
+ }
// TODO: notify the user.
llinfos << "found marker " << ll_install_failed_marker_path() << llendl;
llinfos << "last install attempt failed" << llendl;
@@ -496,6 +503,7 @@ bool LLUpdaterServiceImpl::onMainLoop(LLSD const & event)
LLSD event;
event["type"] = LLSD(LLUpdaterService::INSTALL_ERROR);
+ event["required"] = LLSD(requiredValue);
LLEventPumps::instance().obtain(LLUpdaterService::pumpName()).post(event);
setState(LLUpdaterService::TERMINAL);