mount: resolve hosts to IPs in nfs mounts

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko 2011-11-10 17:01:39 +01:00
parent a86e02492d
commit 39b233182c

View File

@ -1729,7 +1729,7 @@ static int nfsmount(struct mntent *mp, long vfsflags, char *filteropts)
end = strchr(mp->mnt_fsname, ':'); end = strchr(mp->mnt_fsname, ':');
*end = '\0'; *end = '\0';
lsa = xdotted2sockaddr(mp->mnt_fsname, /*port:*/ 0); lsa = xhost2sockaddr(mp->mnt_fsname, /*port:*/ 0);
*end = ':'; *end = ':';
dotted = xmalloc_sockaddr2dotted_noport(&lsa->u.sa); dotted = xmalloc_sockaddr2dotted_noport(&lsa->u.sa);
if (ENABLE_FEATURE_CLEAN_UP) free(lsa); if (ENABLE_FEATURE_CLEAN_UP) free(lsa);