Package: iputils-ping
Version: 3:20100418-3
Severity: normal
In niquery_option_subject_addr_handler, the return value of getaddrinfo is
mischecked, considerated good when != 0,
If getaddrinfo succeed , ping6 will show an error and exit.
If getaddrinfo fails, unitialized memory is used as the struct addrinfo.
-- System Information:
Debian Release: 6.0.5
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'unstable'), (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.36.4 (SMP w/2 CPU cores)
Locale: LANG=fr_FR.utf8, LC_CTYPE=fr_FR.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages iputils-ping depends on:
ii libc6 2.11.3-3 Embedded GNU C Library: Shared lib
ii libssl0.9.8 0.9.8o-4squeeze13 SSL shared libraries
iputils-ping recommends no packages.
iputils-ping suggests no packages.
-- no debconf information
--- ping6.c.old 2012-07-30 21:39:49.000000000 +0200
+++ ping6.c 2012-07-30 21:40:11.000000000 +0200
@@ -357,7 +357,7 @@
hints.ai_socktype = SOCK_DGRAM;
gai = getaddrinfo(arg, 0, &hints, &ai0);
- if (!gai) {
+ if (gai) {
fprintf(stderr, "Unknown host: %s\n", arg);
return -1;
}