svn commit: r236695 - in head/lib/libc: include net
Dimitry Andric
dim at FreeBSD.org
Wed Jun 6 21:16:27 UTC 2012
Author: dim
Date: Wed Jun 6 21:16:26 2012
New Revision: 236695
URL: http://svn.freebsd.org/changeset/base/236695
Log:
Fix two warnings about self-assignment in libc. These normally only
trigger with clang, when you either use -save-temps, or ccache.
Reported by: Sevan / Venture37 <venture37 at gmail.com>
MFC after: 3 days
Modified:
head/lib/libc/include/port_before.h
head/lib/libc/net/getaddrinfo.c
Modified: head/lib/libc/include/port_before.h
==============================================================================
--- head/lib/libc/include/port_before.h Wed Jun 6 18:04:49 2012 (r236694)
+++ head/lib/libc/include/port_before.h Wed Jun 6 21:16:26 2012 (r236695)
@@ -17,6 +17,6 @@
var = _u.v; \
} while (0)
-#define UNUSED(x) (x) = (x)
+#define UNUSED(x) (void)(x)
#endif /* _PORT_BEFORE_H_ */
Modified: head/lib/libc/net/getaddrinfo.c
==============================================================================
--- head/lib/libc/net/getaddrinfo.c Wed Jun 6 18:04:49 2012 (r236694)
+++ head/lib/libc/net/getaddrinfo.c Wed Jun 6 21:16:26 2012 (r236695)
@@ -464,7 +464,7 @@ getaddrinfo(const char *hostname, const
}
error = get_portmatch(pai, servname);
if (error)
- ERR(error);
+ goto bad;
*pai = ai0;
}
More information about the svn-src-head
mailing list