release

Objective C release, autorelease, and data types

I'm new to memory managed code but I get the idea pretty well. On taking my app through the leaks tool in XCode, I noticed I only had to clean up my custom objects, but not dynamically created arrays for example, so I figured those data types are autoreleased - makes sense since I only had to release the arrays I used as properties that...

How to release late bound COM objects?

I guess I do have to release also late bound COM objects. But how is this done directly? In my situation I use the following code from C# to get the focused point from Google Earth (simplified): Type oClassType = Type.GetTypeFromProgID("GoogleEarth.ApplicationGE"); object oGE = Activator.CreateInstance(oClassType); object oCamera = oGE...

OLE DB Release Configuration Problem

When I compile my C# WPF project in release configuration mode with Visual Studio 2008 and run the project on my computer I have no problem at all. If I move the Release directory onto another computer (that does not have Visual Studio) everything seems to work except OLE DB. This is probably because the other computer does not have what...

Release for controllers and views

If I have a set of custom UIViewControllers that I release in a high level application "restart" routine, would a good way to release their views be to set self.view = nil; in the dealloc method? ...

How to be more memory efficient with tab bars and nav controllers?

Background: I have a tab bar controller which currently contains 4 tabs. 3 of the tabs are navigation controllers which display a hierarchy of table views for viewing, editing, and creating data. The data is generally NSStrings that are taken from the user and stored in a global variable (data needs to be accessed from multiple views in ...

Write to Debug in release mode

I have an exception that I need to swallow (exception during logging), however I dont want the exception information to be completely lost to the mists of time and so I figured I may as well at least output it to debug using Debug.Write(ex.ToString()); That way if it becomes necessary support can at least use DebugView on the machine ...

How to release often with Lean/Kanban?

I am quite new to Lean/Kanban, but have poured over online resources over the last few weeks and have come up with a question that I haven't found a good answer for. Lean/Kanban seems otherwise such a good fit for our company, who is already using Scrum, but have reached some limitations inside that methodology. I hope someone here can g...

Objective C : Releasing after removal from an array & reference pointers.

So some where i have a leak which is related to deleting an object under certain circumstances. Premise: - I have an NSMutableArray of Tree objects (a Tree object knows how to draw itself). - I have a reference pointer (Tree *selected) which basically points to whatever tree i last touched. - Note that the *selected pointer is a weak r...

Releasing objects returned by method in Objective-C

Ok, I know the answer to this question should be obvious, but I need a little push in the right direction. I find myself writing a fair number of methods that follow the following pattern: -(NSThing*)myMethod{ NSThing *thing = [[NSthing alloc] init]; // do some stuff with the thing return thing; } My question is, how do I hand...

IClearCase, IClearTool usage in C#, How do I manage memory allocated

On timer tick I am allocating new ClearCase ApplicationClass object, Is following code okay? Or Do I need to release memory, If yes, How? I am using ClearCase Interop of ccauto.dll, I believe ccauto.dll is unmanaged code, I am confused, am I supposed to release the memory or not? Please advise. private void timer1_Tick(object sende...

How to release web applications?

I don't really know how to perform deployment from offline development to live webserver correctly in web development. I mostly resort on intuition, but this is more or less what I did until now: I have a web application in python, or php, and I am hosting it on a live webserver. I use an offline development version whose source is under...

setting objects to nil when releasing NSArray

When I get a memory warning I am releasing a bunch of objects stored in an NSMutableArray. [_children release]; I also need to recurse through objects at some point (potentially after a mem warning has happened), so I need to check if the objects are still around, which I do with comparison to nil- which isn't going to work because re...

What might cause half of an NSData object to stay in memory after releasing it?

I'm loading a series of images from a server into NSData objects like so: for (int i = 0; i < 36; i++) { NSURL *url = [NSURL URLWithString:@"http://12.34.56.78/image.jpg"]; NSData *data = [NSData dataWithContentsOfURL:url]; // Further processing here } The problem is that half of each data object is being kept in memory. This d...

Objective-C/iPhone memory management question

In my iPhone app, I have a "statistics" view that is displayed by the following method - the method itself is called when the user touches a button. This method is in a UINavigationController - (void) showStatsView { StatsViewController *statsViewController = [[StatsViewController alloc] initWithNibName:@"Stats" bundle:[NSBundle mai...

How to release a subset of deliverables?

Hi, Further to my question at accidentally-released-code-to-live-how-to-prevent-happening-again. After client UAT we often have the client saying they are happy for a subset of features to be released while others they want in a future release instead. My question is "How do you release 2/3 (two out of 3) of your features". I'd be inte...

Different approaches to source control branching

When using source control, the way I am used to working is to develop on the trunk and then branch the trunk just prior to moving into QA. I was talking with some other people in the department and apparently there are some passionate views about a different way of working, which would be to create the new branch at the very beginning o...

Releasedate for Rails 3

Does anybody know when Rails 3 will be released? Tried to find info on the net - but nothing useful that I found... ...

How do I release the ACTUAL memory and not just the pointer to the memory?

I am releasing things but the memory seems to still be there according to instruments. Am I just releasing the pointer and not the actual data? How do I release THE DATA in objective-c? What's the difference between [anObject release] or [&anObject release]???? Please excuse my lack of knowledge on the subject of memory and pointers. ...

What is happening to memory when I do this (memory question)?

I am trying to figure out how to pass a UIImage around between various view controllers without duplicating the UIImage and increasing memory unnecessarily. The image is passed successfully using the method below, but I cannot seem to free up this UIImage later on, which ends up weighing down my app with 7MB+ of data that cannot be accou...

iPhone release build not functioning the same as debug build

My program works the way I want it to on both the iPhone simulator and the iPhone itself when using the debug build. However when I change it to the release build, its works on the iPhone simulator but not on the device. I'm trying to animate a ball across the screen with a timer and the ball should bounce off the sides if it collides wi...