We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 62958ed commit 06dc63cCopy full SHA for 06dc63c
Sources/CryptoBoringWrapper/Util/RandomBytes.swift
@@ -21,9 +21,6 @@ extension UnsafeMutableRawBufferPointer {
21
22
#if canImport(Darwin) || os(Linux) || os(Android) || os(Windows)
23
var rng = SystemRandomNumberGenerator()
24
- #else
25
- fatalError("No secure random number generator on this platform.")
26
- #endif
27
precondition(count <= self.count)
28
29
// We store bytes 64-bits at a time until we can't anymore.
@@ -41,6 +38,9 @@ extension UnsafeMutableRawBufferPointer {
41
38
remainingWord >>= 8
42
39
targetPtr = UnsafeMutableRawBufferPointer(rebasing: targetPtr[1...])
43
40
}
+ #else
+ fatalError("No secure random number generator on this platform.")
+ #endif
44
45
46
0 commit comments