Skip to content

Commit 120f749

Browse files
authored
Merge pull request #2236 from compnerd/double-double-toil-and-trouble
TestFoundation: fix a double free
2 parents f4165ce + 2650f0d commit 120f749

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

TestFoundation/TestNSKeyedArchiver.swift

-5
Original file line numberDiff line numberDiff line change
@@ -295,11 +295,6 @@ class TestNSKeyedArchiver : XCTestCase {
295295
let s1 = String(cString: charPtr)
296296
let s2 = String(cString: expectedCharPtr!)
297297

298-
#if !DEPLOYMENT_RUNTIME_OBJC
299-
// On Darwin decoded strings would belong to the autorelease pool, but as we don't have
300-
// one in SwiftFoundation let's explicitly deallocate it here.
301-
expectedCharPtr!.deallocate()
302-
#endif
303298
return s1 == s2
304299
})
305300
}

0 commit comments

Comments
 (0)