Top "Resource-leak" questions

Scanner is never closed

I'm working on a game and I came across a little problem with my scanner. I'm getting a resource leak …

java java.util.scanner resource-leak
What's the upper limit on GDI objects for one process in Windows 7?

Have an application with a GDI leak that will eventually hit 10,000 allocated GDI objects and crash. I tried increasing the …

windows-7 gdi resource-leak
Does DataAdapter.Fill() close its connection when an Exception is thrown?

I am using ADO.NET (.NET 1.1) in a legacy app. I know that DataAdapter.Fill() opens and closes connections if …

.net ado.net .net-1.1 sqlconnection resource-leak
Resource leak warning in eclipse

In Eclipse I received a warning Resource leak: 'ps' is not closed at this location that I don't understand. In …

java eclipse resource-leak
Why is Files.lines (and similar Streams) not automatically closed?

The javadoc for Stream states: Streams have a BaseStream.close() method and implement AutoCloseable, but nearly all stream instances do …

java stream java-8 java-stream resource-leak
Hunting down EOutOfResources

Question: Is there an easy way to get a list of types of resources that leak in a running application? …

delphi gdi resource-leak eoutofresources
Jersey client connection close memory leak issue

I am using Jersey v10 and have written the following code.Is this the right way to close a Jersey …

memory-leaks connection client jersey resource-leak
Do I need to call Close() on a ManualResetEvent?

I've been reading up on .NET Threading and was working on some code that uses a ManualResetEvent. I have found …

c# multithreading dispose waithandle resource-leak
Using statement around dialog form to ensure garbage collection

We have a Windows Forms application that contains thousands of forms. Many of these are temporarily displayed as dialogs via …

c# winforms garbage-collection using-statement resource-leak
How to trace handle leaks?

In one of my applications I observe an increasing number of handles. The number is incremented roughly every second without …

windows delphi delphi-xe resource-leak