summaryrefslogtreecommitdiff
path: root/indra/newview/llurllineeditorctrl.cpp
diff options
context:
space:
mode:
authorChristian Goetze (CG) <cg@lindenlab.com>2010-08-02 22:05:56 -0700
committerChristian Goetze (CG) <cg@lindenlab.com>2010-08-02 22:05:56 -0700
commitd10b9a7f37bec670342136eeea2c8c2604fdfeef (patch)
treea6380a0442d103faed76f1a1c7e5eb03d0f3f6ae /indra/newview/llurllineeditorctrl.cpp
parenta39b31abf87d93fb41212e952cc3ad1d8c91b5ef (diff)
parentb3b8ef25e192f5713c9d5ca47289499b17ff07d1 (diff)
Pulled from "dessie/viewer-release"
Diffstat (limited to 'indra/newview/llurllineeditorctrl.cpp')
-rw-r--r--indra/newview/llurllineeditorctrl.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/indra/newview/llurllineeditorctrl.cpp b/indra/newview/llurllineeditorctrl.cpp
index 8488527185..333f682e8f 100644
--- a/indra/newview/llurllineeditorctrl.cpp
+++ b/indra/newview/llurllineeditorctrl.cpp
@@ -89,9 +89,10 @@ void LLURLLineEditor::copyEscapedURLToClipboard()
const std::string unescaped_text = wstring_to_utf8str(mText.getWString().substr(left_pos, length));
LLWString text_to_copy;
- if (LLSLURL(unescaped_text).isValid())
+ // *HACK: Because LLSLURL is currently broken we cannot use it to check if unescaped_text is a valid SLURL (see EXT-8335).
+ if (LLStringUtil::startsWith(unescaped_text, "http://")) // SLURL
text_to_copy = utf8str_to_wstring(LLWeb::escapeURL(unescaped_text));
- else
+ else // human-readable location
text_to_copy = utf8str_to_wstring(unescaped_text);
gClipboard.copyFromString( text_to_copy );