delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/06/21/02:09:39

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
From: "Peter" <petere AT connexus DOT net DOT au>
Reply-to: petere AT connexus DOT net DOT au
To: cygwin AT cygwin DOT com
Date: Thu, 21 Jun 2001 09:30:15 +1100
Subject: Run-Away memory use by fopen()
X-Mailer: DMailWeb Web to Mail Gateway 2.6z, http://netwinsite.com/top_mail.htm
Message-id: <3b313207.f3dc.0@connexus.net.au>
X-User-Info: 139.130.53.187
MIME-Version: 1.0

Hi,

I've written a program that allocates a large number of small
buffers, then attempts to open a file to write them to disk
before continuing on.  Problem is, that when I try to open
the file, the fopen() does not return, and makes the process
sit there sucking up memory until there is not more memory to use.  If I move
the fopen() before I do any malloc()'s, or I make it such that less allocation
is happening, then the fopen()
works as expected.

Any ideas why this is the case?

System info:
Cygwin DLL version info:
    dll major: 1003
    dll minor: 2
    dll epoch: 19
    dll bad signal mask: 19005
    dll old termios: 5
    dll malloc env: 28
    api major: 0
    api minor: 39
    shared data: 3
    dll identifier: cygwin1
    mount registry: 2
    cygnus registry name: Cygnus Solutions
    cygwin registry name: Cygwin
    program options name: Program Options
    cygwin mount registry name: mounts v2
    cygdrive flags: cygdrive flags
    cygdrive prefix: cygdrive prefix
    cygdrive default prefix:
    build date: Sun May 20 23:28:17 EDT 2001
    shared id: cygwin1S3

GCC Version: 2.95.3-4

Thanks,
Peter

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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