Tue, 20 Nov 2012 15:33:21 -0600
Check if the URLBase is empty in the xml-element instead of reying on it being present. This avioid upnp failing in certain routers.
Thanks Ferdinand Stehle for the patch
Fixes #15373
| COPYRIGHT | file | annotate | diff | comparison | revisions | |
| libpurple/upnp.c | file | annotate | diff | comparison | revisions |
--- a/COPYRIGHT Thu Nov 15 16:09:22 2012 -0600 +++ b/COPYRIGHT Tue Nov 20 15:33:21 2012 -0600 @@ -510,6 +510,7 @@ Lex Spoon Chris Stafford Kevin Stange +Ferdinand Stehle Joshua Stein Jakub Steiner Richard Stellingwerff
--- a/libpurple/upnp.c Thu Nov 15 16:09:22 2012 -0600 +++ b/libpurple/upnp.c Tue Nov 20 15:33:21 2012 -0600 @@ -259,7 +259,9 @@ /* get the baseURL of the device */ if((baseURLNode = xmlnode_get_child(xmlRootNode, "URLBase")) != NULL) { baseURL = xmlnode_get_data(baseURLNode); - } else { + } + /* fixes upnp-descriptions with empty urlbase-element */ + if(baseURL == NULL){ baseURL = g_strdup(httpURL); }