delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/12/10/03:48:21

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <01a001c2a029$0d9950d0$3492fea9@NOELG>
Reply-To: "Noel Gordon" <noelg AT blueskyinternet DOT com DOT au>
From: "Noel Gordon" <noelg AT blueskyinternet DOT com DOT au>
To: <cygwin AT cygwin DOT com>
Subject: cygwin 1.3.17-1 gethostbyname() leak
Date: Tue, 10 Dec 2002 19:48:44 +1100
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.5600

Anyone else confirm that the following program compiled under
gcc 3.2, cygwin 1.3.17-1, on Win2k leaks memory?

/*-----------------------------------------------------------*/

#include <netdb.h>
#include <stdio.h>

int main()
{
  struct hostent *host;

  while ( 1 )
  {
    if ( ( host = gethostbyname( "localhost" ) ) != NULL )
      printf( "gethostbyname(): %s\n", host->h_name );
  }
}





--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019