The result of the get_my_ipv4addr() function is not used in
append_addr_opt(), so remove the call and the ip_addr variable.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Neil Brown <neilb@suse.de>
*/
static int append_addr_opt(const char *spec, char **extra_opts)
{
- static char hostdir[1024], new_opts[1024], ip_addr[255];
+ static char hostdir[1024], new_opts[1024];
char *hostname, *dirname, *s, *old_opts;
struct sockaddr_in addr;
if (!fill_ipv4_sockaddr(hostname, &addr))
return 0;
- if (!get_my_ipv4addr(ip_addr, sizeof(ip_addr)))
- return 0;
/* add IP address to mtab options for use when unmounting */
s = inet_ntoa(addr.sin_addr);