summaryrefslogtreecommitdiff
path: root/net/gupnp/patches/patch-ab
blob: 661c3590030438c23e8c8534e88cf8a9b1243c4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
$NetBSD: patch-ab,v 1.3 2015/01/25 07:43:13 wiz Exp $

More defensive programming.
https://bugzilla.gnome.org/show_bug.cgi?id=743233

--- libgupnp/gupnp-control-point.c.orig	2014-05-31 07:49:41.000000000 +0000
+++ libgupnp/gupnp-control-point.c
@@ -692,7 +692,7 @@ parse_usn (const char *usn,
         /* Count elements */
         count = g_strv_length (bits);
 
-        if (count == 1) {
+        if (count == 1 || (count == 2 && strlen(bits[1]) == 0)) {
                 /* uuid:device-UUID */
 
                 *udn = bits[0];