summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-04-04 18:08:23 -0400
committerPietro Gagliardi <[email protected]>2014-04-04 18:08:23 -0400
commitef43865923219db3e88f85b3ff5dc2210ab4300f (patch)
treed2ca5cdee5b09e5e6b2d1f04694534a8ead4b37e
parentfbde220ab1fad59059161ca6443fa10585dcb7c9 (diff)
Removed objc_release().
-rw-r--r--objc_darwin.go4
-rw-r--r--uitask_darwin.go2
2 files changed, 1 insertions, 5 deletions
diff --git a/objc_darwin.go b/objc_darwin.go
index 8f8ef2c..dce8c0f 100644
--- a/objc_darwin.go
+++ b/objc_darwin.go
@@ -43,10 +43,6 @@ func objc_alloc(class C.id) C.id {
return C.objc_msgSend_noargs(class, _alloc)
}
-func objc_release(obj C.id) {
- C.objc_msgSend_noargs(obj, _release)
-}
-
func toNSString(str string) C.id {
cstr := C.CString(str)
defer C.free(unsafe.Pointer(cstr))
diff --git a/uitask_darwin.go b/uitask_darwin.go
index fa2aa75..c05baf6 100644
--- a/uitask_darwin.go
+++ b/uitask_darwin.go
@@ -50,7 +50,7 @@ func ui(main func()) error {
_uitask,
fp,
C.BOOL(C.YES)) // wait so we can properly drain the autorelease pool; on other platforms we wind up waiting anyway (since the main thread can only handle one thing at a time) so
- objc_release(pool)
+ C.objc_msgSend_noargs(pool, _release)
}
}()