diff options
author | Samu Kallio <samu@samukallio.net> | 2016-01-26 19:26:48 +0200 |
---|---|---|
committer | Samu Kallio <samu@samukallio.net> | 2016-01-26 19:44:20 +0200 |
commit | 963783d7447cad48e594846a865b26535874679d (patch) | |
tree | a0a578c6a1d5e2d56aec3b836bd4b97e43b000be /src | |
parent | 9766c16bd08bd6714064ee950798a6db0874b048 (diff) |
nss-resolve: fix gethostbyaddr h_aliases
Fix the comparison to include the first alias, which will
otherwise be left as a bogus pointer.
Diffstat (limited to 'src')
-rw-r--r-- | src/nss-resolve/nss-resolve.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nss-resolve/nss-resolve.c b/src/nss-resolve/nss-resolve.c index a268c3ac31..2b716a69d1 100644 --- a/src/nss-resolve/nss-resolve.c +++ b/src/nss-resolve/nss-resolve.c @@ -659,7 +659,7 @@ enum nss_status _nss_resolve_gethostbyaddr2_r( p = buffer + idx; memcpy(p, n, l+1); - if (i > 1) + if (i > 0) ((char**) r_aliases)[i-1] = p; i++; |