Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-Id: <380608DB.8795C358@crocodial.de> Date: Thu, 14 Oct 1999 18:46:19 +0200 From: Benjamin Riefenstahl Organization: Crocodial Communications EntwicklungsGmbH X-Mailer: Mozilla 4.05 [en] (Win16; I) MIME-Version: 1.0 To: cygwin AT sourceware DOT cygnus DOT com Subject: Re: mingw32 and winsocks References: <001701bf1608$d0e23ba0$028891c2 AT shadow DOT sk> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id MAA02513 Hi Marcel, Marcel Mojžiš wrote: > I have a question about using winsocks with mingw32. I compiled libpq > frontend library using mingw32 (gcc 2.95). There was no problem with the > [...] > #include > #include > > void main() { > if (gethostbyname("www.microsoft.com") == NULL) { > printf("failed..."); > } > } I think you are missing a call to WSAStartup() here to initialize WinSock. so long, benny ====================================== Benjamin Riefenstahl (benny AT crocodial DOT de) Crocodial Communications GmbH Ruhrstr. 61, D-22761 Hamburg, Germany -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com