summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterfixedenvironment.cpp
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2018-07-03 14:18:24 -0700
committerRider Linden <rider@lindenlab.com>2018-07-03 14:18:24 -0700
commita4137d72ebc9f49dfd8bd124b255da0dfbc4ba92 (patch)
tree5781b8ad54f1c26674a3e5085a76c77450c5261e /indra/newview/llfloaterfixedenvironment.cpp
parentab159f7c4a35196003add5592df95fe2c139984e (diff)
MAINT-8821: New "My Environments" floater. First pass.
Diffstat (limited to 'indra/newview/llfloaterfixedenvironment.cpp')
-rw-r--r--indra/newview/llfloaterfixedenvironment.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/indra/newview/llfloaterfixedenvironment.cpp b/indra/newview/llfloaterfixedenvironment.cpp
index 7efd45ca56..fd72bb3624 100644
--- a/indra/newview/llfloaterfixedenvironment.cpp
+++ b/indra/newview/llfloaterfixedenvironment.cpp
@@ -317,8 +317,12 @@ void LLFloaterFixedEnvironment::doApplyEnvironment(const std::string &where)
if (!parcel)
parcel = LLViewerParcelMgr::instance().getAgentParcel();
- if (!parcel)
+ if ((!parcel) || (parcel->getLocalID() == INVALID_PARCEL_ID))
+ {
+ LL_WARNS("ENVIRONMENT") << "Can not identify parcel. Not applying." << LL_ENDL;
+ LLNotificationsUtil::add("WLParcelApplyFail");
return;
+ }
if (mSettings->getSettingsType() == "sky")
LLEnvironment::instance().updateParcel(parcel->getLocalID(), std::static_pointer_cast<LLSettingsSky>(mSettings), -1, -1);