From: Aaron Lipinski Date: Tue, 6 Apr 2021 00:25:12 +0000 (+1200) Subject: remove wrapper only function X-Git-Tag: v0.95~6^2~14 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=571004f8544ee638a2667c4f39bc9022a503915d;p=thirdparty%2Fmtr.git remove wrapper only function --- diff --git a/ui/dns.c b/ui/dns.c index 902aa67..8f47316 100644 --- a/ui/dns.c +++ b/ui/dns.c @@ -87,18 +87,6 @@ static int longipstr( } -struct hostent *dns_forward( - const char *name) -{ - struct hostent *host; - - if ((host = gethostbyname(name))) - return host; - else - return NULL; -} - - static struct dns_results *findip( struct mtr_ctl *ctl, ip_t * ip) diff --git a/ui/dns.h b/ui/dns.h index 921110e..918bc51 100644 --- a/ui/dns.h +++ b/ui/dns.h @@ -41,8 +41,6 @@ extern char *dns_lookup( extern char *dns_lookup2( struct mtr_ctl *ctl, ip_t * address); -extern struct hostent *dns_forward( - const char *name); extern char *strlongip( sa_family_t family, ip_t * ip); diff --git a/ui/gtk.c b/ui/gtk.c index e23abf2..a98154a 100644 --- a/ui/gtk.c +++ b/ui/gtk.c @@ -246,7 +246,7 @@ static gint Host_activate( struct mtr_ctl *ctl = (struct mtr_ctl *) data; struct hostent *addr; - addr = dns_forward(gtk_entry_get_text(GTK_ENTRY(entry))); + addr = gethostbyname(gtk_entry_get_text(GTK_ENTRY(entry))); if (addr) { net_reopen(ctl, addr); net_send_batch(ctl);