MAINT-8403 Restore fail case for general upload snapshot

meow-7.2.2
maxim_productengine 2018-03-22 12:21:38 +02:00
parent 925ae4cf38
commit 00c6c29daf
1 changed files with 10 additions and 2 deletions

View File

@ -865,10 +865,18 @@ void LLViewerAssetUpload::HandleUploadError(LLCore::HttpStatus status, LLSD &res
// Let the Snapshot floater know we have failed uploading.
LLFloaterSnapshot* floater_snapshot = LLFloaterSnapshot::findInstance();
if (uploadInfo->getAssetType() == LLAssetType::AT_IMAGE_JPEG && floater_snapshot && floater_snapshot->isWaitingState())
if (floater_snapshot && floater_snapshot->isWaitingState())
{
floater_snapshot->notify(LLSD().with("set-finished", LLSD().with("ok", false).with("msg", "postcard")));
if (uploadInfo->getAssetType() == LLAssetType::AT_IMAGE_JPEG)
{
floater_snapshot->notify(LLSD().with("set-finished", LLSD().with("ok", false).with("msg", "postcard")));
}
if (uploadInfo->getAssetType() == LLAssetType::AT_TEXTURE)
{
floater_snapshot->notify(LLSD().with("set-finished", LLSD().with("ok", false).with("msg", "inventory")));
}
}
LLFloater* floater_outfit_snapshot = LLFloaterReg::findInstance("outfit_snapshot");
if (uploadInfo->getAssetType() == LLAssetType::AT_TEXTURE && floater_outfit_snapshot && floater_outfit_snapshot->isShown())
{