Skip to content

Commit

Permalink
Balance your retains and releases.
Browse files Browse the repository at this point in the history
Improves .gitignore too.
  • Loading branch information
btrask authored and Alexander Staubo committed Jun 17, 2009
1 parent 35f0f67 commit 8ae4bd9
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
6 changes: 5 additions & 1 deletion .gitignore
@@ -1,5 +1,9 @@
.DS_Store
/build
*~
Keywurl.xcodeproj/alex*
Installer/Install Keywurl.pkg
*.pbxuser
*.mode1
*.mode1v3
*.perspective
*.perspectivev3
11 changes: 9 additions & 2 deletions KeywordSaveController.m
Expand Up @@ -47,8 +47,8 @@ - (id) initWithUrl: (NSString*) theUrl
inputElement: (DOMElement*) theInputElement
formElement: (DOMElement*) theFormElement {
url = [theUrl copy];
inputElement = theInputElement;
formElement = theFormElement;
inputElement = [theInputElement retain];
formElement = [theFormElement retain];
if (![NSBundle loadNibNamed: @"SaveKeywordWindow" owner: self]) {
NSLog(@"Could not load resource.");
return nil;
Expand Down Expand Up @@ -85,6 +85,13 @@ - (id) initWithUrl: (NSString*) theUrl
contextInfo: nil];
return self;
}
- (void)dealloc
{
[url release];
[inputElement release];
[formElement release];
[super dealloc];
}

- (void) saveKeyword: (id) sender {
NSMutableArray* fields = [NSMutableArray new];
Expand Down

0 comments on commit 8ae4bd9

Please sign in to comment.