diff options
author | Richard Nelson <none@none> | 2010-05-26 14:47:48 -0700 |
---|---|---|
committer | Richard Nelson <none@none> | 2010-05-26 14:47:48 -0700 |
commit | 0f86f811c269b7c45baae2ac9bc72df70ba6b520 (patch) | |
tree | 133c34db6187f2d7092ed775b23157cba1420228 /indra | |
parent | f87f436fda8ad41637d98332748681ea315279cc (diff) |
DEV-50271 FIX SLURL support for non-clickable display names
std::multimap::find does *not* return an iterator just to the matching results, use std::multimap::equal_range instead
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llui/llurlentry.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index 13fd20faf8..472c15a240 100644 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -160,8 +160,9 @@ void LLUrlEntryBase::callObservers(const std::string &id, const std::string &icon) { // notify all callbacks waiting on the given uuid - std::multimap<std::string, LLUrlEntryObserver>::iterator it; - for (it = mObservers.find(id); it != mObservers.end();) + typedef std::multimap<std::string, LLUrlEntryObserver>::iterator observer_it; + std::pair<observer_it, observer_it> matching_range = mObservers.equal_range(id); + for (observer_it it = matching_range.first; it != matching_range.second;) { // call the callback - give it the new label LLUrlEntryObserver &observer = it->second; @@ -342,8 +343,9 @@ void LLUrlEntryAgent::callObservers(const std::string &id, const std::string &icon) { // notify all callbacks waiting on the given uuid - std::multimap<std::string, LLUrlEntryObserver>::iterator it; - for (it = mObservers.find(id); it != mObservers.end();) + typedef std::multimap<std::string, LLUrlEntryObserver>::iterator observer_it; + std::pair<observer_it, observer_it> matching_range = mObservers.equal_range(id); + for (observer_it it = matching_range.first; it != matching_range.second;) { // call the callback - give it the new label LLUrlEntryObserver &observer = it->second; |