Correct return value from gst_udp_get_addr() when no known family is found.
authorPeter Kjellerstedt <pkj@axis.com>
Thu, 22 Jan 2009 14:59:40 +0000 (15:59 +0100)
committerPeter Kjellerstedt <pkj@axis.com>
Mon, 26 Jan 2009 14:49:22 +0000 (15:49 +0100)
gst/udp/gstudpnetutils.c

index 93915a5..a1588ca 100644 (file)
@@ -104,8 +104,7 @@ gst_udp_get_addr (const char *hostname, int port, struct sockaddr_storage *addr)
   if (nres) {
     memcpy (addr, nres->ai_addr, nres->ai_addrlen);
   } else {
-    errno = EAI_ADDRFAMILY;
-    ret = -1;
+    ret = EAI_ADDRFAMILY;
   }
 
 beach: