From 77bca92a02d1e063fa77caf4c6a40c620d865472 Mon Sep 17 00:00:00 2001 From: Jarl Gullberg Date: Fri, 4 Aug 2017 18:46:17 +0200 Subject: [PATCH] Use local variable instead of reusing the field. --- src/OpenTK/Platform/MacOS/Cocoa/NSAutoreleasePool.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/OpenTK/Platform/MacOS/Cocoa/NSAutoreleasePool.cs b/src/OpenTK/Platform/MacOS/Cocoa/NSAutoreleasePool.cs index 074e65a8..e6ba6c42 100644 --- a/src/OpenTK/Platform/MacOS/Cocoa/NSAutoreleasePool.cs +++ b/src/OpenTK/Platform/MacOS/Cocoa/NSAutoreleasePool.cs @@ -16,8 +16,8 @@ namespace OpenTK.Platform.MacOS /// public NSAutoreleasePool() { - _autoreleasePool = Cocoa.SendIntPtr(Class.NSAutoreleasePool, Selector.Alloc); - _autoreleasePool = Cocoa.SendIntPtr(_autoreleasePool, Selector.Init); + var uninitializedPool = Cocoa.SendIntPtr(Class.NSAutoreleasePool, Selector.Alloc); + _autoreleasePool = Cocoa.SendIntPtr(uninitializedPool, Selector.Init); } ///