memory-leaks

When and how is a java classloader marked for garbage collection?

We are creating multiple child classloaders to load in multiple subapplications into a Java application "container", prototyping hot deployment. When the classpath of a particular classloader has changed (i.e. jars have been added, deleted, updated), the old classloader is thrown away (unreferenced) and a new classloader is created for ...

Is there a best way to automate the memory leak test?

We are in a process of automating the most of known issues(for regression testing) that can be automated. However, we do find memory leaks through third party software. However, I do not know the way to automate the memory leak test that we found and fixed them. Is there any advise on it? ...

UISearchBar Memory Leak?

My app is a tableview with a searchbar and scope buttons. I commented out the functionality of the app in order to diagnose why real memory keeps rising. As soon as I type a letter in the search bar textbox, the keyboard appears and real memory rises by .20MB. Even if I backspace, the memory goes up. If I do enough searches, eventually I...

CellForRowAtIndexPath Causing issues, when can I release a local inside there?

Hey all, I have a UITableView that displays various nsstrings from a custom object called a "Transaction." in CellForRowAtIndexPath it the allocates a new instance of a transaction and then copies the the values from a particular transaction that lives in the delegate array so I can access it from different views. It then uses the new ...

Core Data / NSArray Causing Leaks?

I am having a specific leak that I can't seem to dig to the bottom of, cause my search always ends up in some Apple libraries. Any help from some veterans at dealing with this would be appreciated. Here is the relevant source code: (leak indicated with a comment) - (void)viewDidLoad { //[super viewDidLoad]; NSManagedObjectContext *con...

Do I trust ObjectAlloc or Leaks for analyzing my iPhone app?

When I run my iPhone app with "Leaks" (which has a section for Object Alloc), my app seems to be fine for memory allocation. However, when I run it with just the ObjectAlloc tool, the memory increases steadily as the app runs its main timer. (It is a timer based app). I'm not sure what to trust. I was just wondering if there are any ...

ASP.NET app using lots of memory - Leak?

Hi All, I have an ASP.NET website that seems to be using a lot of memory. I left it for 7 hours on Sunday and it reached 3.2gb. I thought .NET handled all it's own garbage collection / free'd objects and so on, so I am not really sure where to start looking for a solution. The website uses XML's heavily so I thought this could be the ...

WPF Memory Leak but only when total document footprint exceeds threshold.

WPF Memory Leak Problem. Memory stable with small documents, but grows until OOM exception with large documents. Background: We've developed a WPF application for controlling a dynamic display. There is a Design component, where the user lays out the display document, and a document Display component. Elements in the display can con...

iphone tableview cells memory leak?

SO, I have a tableview with 20 cells each with a text title, a subtitle label and a textfield (with a button to give it a nice background), but I find that after scrolling the tableview a few times it starts to slow down in the simulator. I figure this is a memory leak, but I thought I'd already released everything that I needed. Any c...

StructureMap ObjectFactory.Reset memory leak?

Here's the simple test to reproduce the issue, this is the single class in the whole project and there are no other references: [TestFixture] public class ObjectFactoryTests { [Test] public void ResetMemoryLeak() { for (int i = 1; i < 1000; i++) { ObjectFactory.Reset(); if (i % 10 == 0...

Memory warning and crash: how to handle it

I use instruments to see memory leaks. At least in one scenario where I am constantly flicking through slides/pages (inside UIScrollView) I don't see any memory leak. Using instruments - under "Allocation lifespan" I switch to view "Created & Still Living" and see memory around 1.17MB throughout. I assume this means my app is using only...

resizing images will giving memory warning

hi, I am developing image framing application for iphone. when i choose image from image-picker controller and after zooming , cropping,pairing with frame i will save the image. for that i am drawing image context over image. actually my image is of 1200*1600 size but our connivance taking image frame of 320*480. so after drawing ima...

Memory leak in .NET Garbage Collector with System.Transactions.SafeIUnknown

Hi Folks, I'm trying to track down a memory leak in an application using ANTS profiler. I tracked it down to the Garbage collector where we have a list of objects System.Transactions.SafeIUnknown that sit there forever in the garbage collector, are in the finalizer queue but never get released. I can find not documentation what so ever ...

Java 3D Memory Leak

I have a large scene graph in Java 3D consisting out of a Group which contains around 3500 Switches, each containing a Shape3D and a Group, the latter contains two more Shape3Ds. The reason for this setup is that each of the 3500 Switches must be able to be either completely hidden or have either of its two children visible. The proble...

Special PHP Errors

How can PHP cause memory leaks, buffer overflows, stack overflows and any other errors of such kind? Can PHP even cause such errors? ...

Memory Leaks and Apache

My VPS account has been occasionally running out of memory. It's using Apache on Linux. Support says it's a slow memory leak and has enabled MaxRequestsPerChild to deal with it. I have a few questions about this. When a child process dies, will it cause my scripts to lose session data? Does anyone have advice on how I can track down thi...

Memory Leaks - STL sets

I am trying to plug up all my memory leaks (which is massive). I am new to STL. I have a class library where I have 3 sets. I am also creating a lot of memory with new in the library class for adding info to the sets... Do I need to deallocate the sets? If so, how? Here is the library.h #pragma once #include <ostream> #include <m...

What are some of the best Javascript memory detecting tools?

Our team is faced with slow but serious Javascript memory leak. We have read up on the normal causes for memory leaks in Javascript (eg. closures and circular references). We tried to avoid those pitfalls in the code but it likely we still have unknown mistakes left. I started my search for available tools but would like input from pe...

Implement JNI listener.

I have the following code in a c++ "listener class" (more or less), which calls some function of a Java object. I suspect there's a memory leak: JNIEnv *env = NULL; vm_->AttachCurrentThread(&env, NULL); const jclass cls = env->FindClass(...); const jmethodID meth = env->GetMethodID(...); const jobject obj = env->NewObject(cls, meth, ......

Copying a java text file into a String.

Hi, I run into the following errors when i try to store a large file into a string. Exception in thread "main" java.lang.OutOfMemoryError: Java heap space at java.util.Arrays.copyOf(Arrays.java:2882) at java.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:100) at java.lang.AbstractStringBuilder.append(A...