This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Shell script loop runs out of memory


On 05/31/2012 11:42 AM, Jordan wrote:
> Hi folks,
> 
> I've written a shell script running under CygWin, the purpose of which is to 
> monitor a file for changes. If the MD5 hash fails to match the previous hash, it 
> will execute a command to process the file. I used a 1-second delay between 
> checks of the hash. This works great for several hours, but then gives an "out 
> of memory" error and actually brings Windows 7 to its knees.

Have you ascertained whether the leak is in bash, cygwin1.dll, or in
Windows itself?  If it is BLODA (and the leak is in windows itself),
then there is nothing we can do.  If it is in cygwin1.dll, then the leak
would be present even if you used a different shell, and fixing it would
benefit all cygwin programs.  I will also note that cygwin is currently
on bash 4.1, but upstream is at bash 4.2, so there may be a memory leak
patch for bash that we would get if I ever had time to upgrade to the
latest upstream bash.

-- 
Eric Blake   eblake@redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]