• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Troubles with popUpCell and tableview
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Troubles with popUpCell and tableview


  • Subject: Re: Troubles with popUpCell and tableview
  • From: Matt Neuburg <email@hidden>
  • Date: Wed, 11 Sep 2002 07:53:47 -0700

On Tue, 10 Sep 2002 12:00:28 +0200, kubernan <email@hidden> said:

> NSTableColumn *tabColumn = [NSTableColumn alloc];
> tabColumn = [tab tableColumnWithIdentifier:@"function"];

First you allocate a new NSTableColumn; then in the next line you throw
away the newly allocated NSTableColumn and point tabColumn at an already
existing column. The alloc in the first line is a complete waste.

> [tabColumn release];

tabColumn is not yours to release. You have pointed it at one of tab's
columns; then you dare to release it out from under poor tab. This is not a
nice way to treat your table. :)

I suggest you read the note I posted here on basic memory management:

http://cocoa.mamasam.com/COCOADEV/2002/07/2/40541.php

m.
--

matt neuburg, phd = email@hidden, http://www.tidbits.com/matt
pantes anthropoi tou eidenai oregontai phusei
Subscribe to TidBITS! It's free and smart. http://www.tidbits.com/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: NSDocumentController Problems
  • Next by Date: contextual menu with unicode characters
  • Previous by thread: Troubles with popUpCell and tableview
  • Next by thread: Re: Troubles with popUpCell and tableview
  • Index(es):
    • Date
    • Thread