summaryrefslogtreecommitdiff
path: root/indra/newview/llurlhistory.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llurlhistory.cpp')
-rw-r--r--indra/newview/llurlhistory.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/indra/newview/llurlhistory.cpp b/indra/newview/llurlhistory.cpp
index 8f9c926616..d5241a4e98 100644
--- a/indra/newview/llurlhistory.cpp
+++ b/indra/newview/llurlhistory.cpp
@@ -62,6 +62,7 @@ bool LLURLHistory::loadFile(const LLString& filename)
llinfos << "file missing, ill-formed, "
"or simply undefined; not changing the"
" file" << llendl;
+ sHistorySD = LLSD();
return false;
}
}
@@ -100,8 +101,11 @@ LLSD LLURLHistory::getURLHistory(const std::string& collection)
// static
void LLURLHistory::addURL(const std::string& collection, const std::string& url)
{
- sHistorySD[collection].insert(0, url);
- LLURLHistory::limitSize(collection);
+ if(! url.empty())
+ {
+ sHistorySD[collection].insert(0, url);
+ LLURLHistory::limitSize(collection);
+ }
}
// static
void LLURLHistory::removeURL(const std::string& collection, const std::string& url)