# HG changeset patch # User Luke Schierer # Date 1177617849 0 # Node ID 81e3c44ecaac012d99090ee54eb6752a32c62c33 # Parent e3401609d37736e953258e5c2136bdca54256157# Parent 27dfbca8dd405818d204561bc9141001ba2a61bc merge of 'a236381404a31c3fc3022f03ec28de22f6fd1258' and 'ec4bf7641bb15de964f361b7b53db8ceb143258f' diff -r e3401609d377 -r 81e3c44ecaac libpurple/purple-url-handler --- a/libpurple/purple-url-handler Thu Apr 26 20:04:02 2007 +0000 +++ b/libpurple/purple-url-handler Thu Apr 26 20:04:09 2007 +0000 @@ -92,13 +92,13 @@ def aim(uri): protocol = "prpl-aim" - match = re.match(r"^(aim):([^?]*)(\?(.*))", uri) + match = re.match(r"^aim:([^?]*)(\?(.*))", uri) if not match: print "Invalid aim URI: %s" % uri return - command = urllib.unquote_plus(match.group(2)) - paramstring = match.group(4) + command = urllib.unquote_plus(match.group(1)) + paramstring = match.group(3) params = {} if paramstring: for param in paramstring.split("&"): @@ -129,13 +129,13 @@ def icq(uri): protocol = "prpl-icq" - match = re.match(r"^(icq):([^?]*)(\?(.*))", uri) + match = re.match(r"^icq:([^?]*)(\?(.*))", uri) if not match: - print "Invalid aim URI: %s" % uri + print "Invalid icq URI: %s" % uri return - command = urllib.unquote_plus(match.group(2)) - paramstring = match.group(4) + command = urllib.unquote_plus(match.group(1)) + paramstring = match.group(3) params = {} if paramstring: for param in paramstring.split("&"): @@ -225,26 +225,26 @@ def xmpp(uri): protocol = "prpl-jabber" - match = re.match(r"^xmpp:((//)?([^/?#]*))?(/?([^?#]*))(\?([^;#]*)(;([^#]*))?)?(#(.*))?", uri) + match = re.match(r"^xmpp:(//([^/?#]*)/?)?([^?#]*)(\?([^;#]*)(;([^#]*))?)?(#(.*))?", uri) if not match: print "Invalid xmpp URI: %s" % uri return - tmp = match.group(3) + tmp = match.group(2) if (tmp): accountname = urllib.unquote_plus(tmp) else: accountname = "" - screenname = urllib.unquote_plus(match.group(5)) + screenname = urllib.unquote_plus(match.group(3)) - tmp = match.group(7) + tmp = match.group(5) if (tmp): command = urllib.unquote_plus(tmp) else: command = "" - paramstring = match.group(9) + paramstring = match.group(7) params = {} if paramstring: for param in paramstring.split(";"):