views:

23

answers:

0

Hi Guys, If I do nil, I am not getting the leaks but I am getting the exceptions due to nil object. I am getting its retain count as 4. How can I make its retain count to 0

- (void) dealloc
{
printf("\n Hai I am in Dealloc Method of Customer Lib Xml Parser......................");
self.connection = nil;
xmlFreeParserCtxt(_xmlParserContext);
_xmlParserContext = NULL;
self.propertyValue = nil;
self.delegate = nil;
self.retrieverQueue = nil;
printf("\n retain count of customerDetailsObj ................%d",[self.customerDetailsObj retainCount]);

[self.customerDetailsObj release];

    self.customerDetailsObj = nil // here I am getting an exception and object becoming nil.
self.contactsObj=nil;

[super dealloc];
}

Thank You, Madan Mohan