You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ISO8601DateFormatter in swift-corelibs-foundation is not thread-safe.
However, URLEncodedFormDecoder and URLEncodedFormEncoder use this class as a singleton. This can cause a runtime crash, such as a segmentation fault.
I couldn't get it to crash, but I've still got rid of the global instance.
Fixed in #274
I thought this had been fixed in corelibs foundation, but looking through issues it doesn't look like it has. I doubt it will now and we'll have to wait for the new Foundation
Problem
The
ISO8601DateFormatter
inswift-corelibs-foundation
is not thread-safe.However,
URLEncodedFormDecoder
andURLEncodedFormEncoder
use this class as a singleton. This can cause a runtime crash, such as a segmentation fault.Reference to the code:
hummingbird/Sources/HummingbirdFoundation/Codable/URLEncodedForm/URLEncodedForm.swift
Lines 51 to 55 in d7fb66e
Steps to Reproduce
The following code, when run multiple times in a Linux Swift environment, sometimes causes a crash:
Tested Environment
The text was updated successfully, but these errors were encountered: