mirror of
https://github.com/maxgoedjen/secretive.git
synced 2026-03-05 17:27:24 +01:00
Update for Big Sur & SwiftUI 2 (#128)
This commit is contained in:
@@ -33,7 +33,7 @@ public class SocketController {
|
||||
addr.sun_family = sa_family_t(AF_UNIX)
|
||||
|
||||
var len: Int = 0
|
||||
_ = withUnsafeMutablePointer(to: &addr.sun_path.0) { pointer in
|
||||
withUnsafeMutablePointer(to: &addr.sun_path.0) { pointer in
|
||||
path.withCString { cstring in
|
||||
len = strlen(cstring)
|
||||
strncpy(pointer, cstring, len)
|
||||
@@ -42,7 +42,7 @@ public class SocketController {
|
||||
addr.sun_len = UInt8(len+2)
|
||||
|
||||
var data: Data!
|
||||
_ = withUnsafePointer(to: &addr) { pointer in
|
||||
withUnsafePointer(to: &addr) { pointer in
|
||||
data = Data(bytes: pointer, count: MemoryLayout<sockaddr_un>.size)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user