Browse Source

Removed SecCertificate array workaround in ServerTrustPolicy for Xcode 7.2.

Christian Noon 10 years ago
parent
commit
140bce9e72
2 changed files with 2 additions and 10 deletions
  1. 1 2
      README.md
  2. 1 8
      Source/ServerTrustPolicy.swift

+ 1 - 2
README.md

@@ -25,7 +25,7 @@ Alamofire is an HTTP networking library written in Swift.
 ## Requirements
 ## Requirements
 
 
 - iOS 8.0+ / Mac OS X 10.9+ / tvOS 9.0+ / watchOS 2.0+
 - iOS 8.0+ / Mac OS X 10.9+ / tvOS 9.0+ / watchOS 2.0+
-- Xcode 7.1+
+- Xcode 7.2+
 
 
 ## Migration Guides
 ## Migration Guides
 
 
@@ -1126,7 +1126,6 @@ In order to keep Alamofire focused specifically on core networking implementatio
 
 
 The following rdars have some affect on the current implementation of Alamofire.
 The following rdars have some affect on the current implementation of Alamofire.
 
 
-* [rdar://22024442](http://www.openradar.me/radar?id=6082025006039040) - Array of [SecCertificate] crashing Swift 2.0 compiler in optimized builds
 * [rdar://21349340](http://www.openradar.me/radar?id=5517037090635776) - Compiler throwing warning due to toll-free bridging issue in test case
 * [rdar://21349340](http://www.openradar.me/radar?id=5517037090635776) - Compiler throwing warning due to toll-free bridging issue in test case
 
 
 ## FAQ
 ## FAQ

+ 1 - 8
Source/ServerTrustPolicy.swift

@@ -193,14 +193,7 @@ public enum ServerTrustPolicy {
                 serverTrustIsValid = trustIsValid(serverTrust)
                 serverTrustIsValid = trustIsValid(serverTrust)
             } else {
             } else {
                 let serverCertificatesDataArray = certificateDataForTrust(serverTrust)
                 let serverCertificatesDataArray = certificateDataForTrust(serverTrust)
-
-                //======================================================================================================
-                // The following `[] +` is a temporary workaround for a Swift 2.0 compiler error. This workaround should
-                // be removed once the following radar has been resolved:
-                //   - http://openradar.appspot.com/radar?id=6082025006039040
-                //======================================================================================================
-
-                let pinnedCertificatesDataArray = certificateDataForCertificates([] + pinnedCertificates)
+                let pinnedCertificatesDataArray = certificateDataForCertificates(pinnedCertificates)
 
 
                 outerLoop: for serverCertificateData in serverCertificatesDataArray {
                 outerLoop: for serverCertificateData in serverCertificatesDataArray {
                     for pinnedCertificateData in pinnedCertificatesDataArray {
                     for pinnedCertificateData in pinnedCertificatesDataArray {