diff --git a/appl/ftp/ftp/ftp.c b/appl/ftp/ftp/ftp.c index 2a683b7db..181d6b3ff 100644 --- a/appl/ftp/ftp/ftp.c +++ b/appl/ftp/ftp/ftp.c @@ -64,10 +64,10 @@ hookup(char *host, int port) } else { hp = gethostbyname(host); if (hp == NULL) { -#ifdef __CYGWIN32__ - warnx("%s: %s", host, "unknown error"); -#else +#ifdef HAVE_H_ERRNO warnx("%s: %s", host, hstrerror(h_errno)); +#else + warnx("%s: %s", host, "unknown error"); #endif code = -1; return NULL;