]> source.dussan.org Git - tigervnc.git/commitdiff
family variable can be unset when matching any address
authorPierre Ossman <ossman@cendio.se>
Tue, 17 Mar 2015 11:56:31 +0000 (12:56 +0100)
committerPierre Ossman <ossman@cendio.se>
Tue, 17 Mar 2015 11:56:31 +0000 (12:56 +0100)
common/network/TcpSocket.cxx

index 6fca3018a72c28776c6c85181b15ebf220b41ca4..47c2a048ce9c48772fb155454e2a0145f4a93df2 100644 (file)
@@ -848,6 +848,8 @@ TcpFilter::Pattern TcpFilter::parsePattern(const char* p) {
     }
   }
 
+  family = pattern.address.u.sa.sa_family;
+
   if (pattern.prefixlen > (family == AF_INET ? 32: 128))
     throw Exception("invalid prefix length for filter address: %u",
                     pattern.prefixlen);