# HG changeset patch # User Paul Aurich # Date 1260258183 0 # Node ID 7fb15df96ef40a7b9cf5b66ab6253369b3130918 # Parent 592d382e1bf4eac9f9fd3395d33ddf506d980e47# Parent 088fac135139f8a4e37128f48c3d389d0497ee12 merge of '05176515f0fedf038217d2e11e4e3a1c92cad166' and '34ae591131a579911cfae8a20bcf7231fd20aff2' diff -r 592d382e1bf4 -r 7fb15df96ef4 libpurple/protocols/jabber/libxmpp.c --- a/libpurple/protocols/jabber/libxmpp.c Tue Dec 08 04:52:50 2009 +0000 +++ b/libpurple/protocols/jabber/libxmpp.c Tue Dec 08 07:43:03 2009 +0000 @@ -295,7 +295,7 @@ static gboolean xmpp_uri_handler(const char *proto, const char *user, GHashTable *params) { - char *acct_id = g_hash_table_lookup(params, "account"); + char *acct_id = params ? g_hash_table_lookup(params, "account") : NULL; PurpleAccount *acct; if (g_ascii_strcasecmp(proto, "xmpp")) @@ -307,7 +307,8 @@ return FALSE; /* xmpp:romeo@montague.net?message;subject=Test%20Message;body=Here%27s%20a%20test%20message */ - if (g_hash_table_lookup_extended(params, "message", NULL, NULL)) { + /* params is NULL if the URI has no '?' (or anything after it) */ + if (!params || g_hash_table_lookup_extended(params, "message", NULL, NULL)) { char *body = g_hash_table_lookup(params, "body"); if (user && *user) { PurpleConversation *conv =