diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1996-11-21 20:39:57 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1996-11-21 20:39:57 +0000 |
commit | 5d886c3c99aa8db3723f7e5e55411a212ef57a23 (patch) | |
tree | 5b96df4ace2a29215dffcdc46b17cdf2089507a4 | |
parent | e6ebb20b2bf2e28d52fa4c14abd8d3beff4c5826 (diff) | |
download | fetchmail-5d886c3c99aa8db3723f7e5e55411a212ef57a23.tar.gz fetchmail-5d886c3c99aa8db3723f7e5e55411a212ef57a23.tar.bz2 fetchmail-5d886c3c99aa8db3723f7e5e55411a212ef57a23.zip |
Better initialization error message.
svn path=/trunk/; revision=567
-rw-r--r-- | fetchmail.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fetchmail.c b/fetchmail.c index ebb2b899..49355f5c 100644 --- a/fetchmail.c +++ b/fetchmail.c @@ -325,10 +325,14 @@ int main (int argc, char **argv) struct hostent *namerec; /* compute the canonical name of the host */ + errno = 0; namerec = gethostbyname(ctl->servername); if (namerec == (struct hostent *)NULL) { - fprintf(stderr, + if (errno) + perror("fetchmail: initialization error"); + else + fprintf(stderr, "fetchmail: skipping %s poll, nameserver isn't responding\n", ctl->servername); continue; |