diff options
Diffstat (limited to 'libs/pbd/convert.cc')
-rw-r--r-- | libs/pbd/convert.cc | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/libs/pbd/convert.cc b/libs/pbd/convert.cc index 598473c244..622e1dfdd4 100644 --- a/libs/pbd/convert.cc +++ b/libs/pbd/convert.cc @@ -31,7 +31,6 @@ using std::string; using std::vector; -using Glib::ustring; namespace PBD { @@ -196,51 +195,6 @@ url_decode (string& url) } } -void -url_decode (ustring& url) -{ - ustring::iterator last; - ustring::iterator next; - - for (ustring::iterator i = url.begin(); i != url.end(); ++i) { - if ((*i) == '+') { - next = i; - ++next; - url.replace (i, next, 1, ' '); - } - } - - if (url.length() <= 3) { - return; - } - - last = url.end(); - - --last; /* points at last char */ - --last; /* points at last char - 1 */ - - for (ustring::iterator i = url.begin(); i != last; ) { - - if (*i == '%') { - - next = i; - - url.erase (i); - - i = next; - ++next; - - if (isxdigit (*i) && isxdigit (*next)) { - /* replace first digit with char */ - url.replace (i, next, 1, (gunichar) int_from_hex (*i,*next)); - ++i; /* points at 2nd of 2 digits */ - url.erase (i); - } - } else { - ++i; - } - } -} #if 0 string |