Skip to content

Commit 35b9955

Browse files
committed
Fix CFURLSession_easy_setopt_ptr
1 parent 7f52f2c commit 35b9955

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Sources/FoundationNetworking/URLSession/libcurl/EasyHandle.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,9 @@ extension _EasyHandle {
276276

277277
try! fs.close()
278278

279-
try! CFURLSession_easy_setopt_ptr(rawHandle, CFURLSessionOptionCAINFO, aggregateCertPath).asError()
279+
aggregateCertPath.withCString { pathPtr in
280+
try! CFURLSession_easy_setopt_ptr(rawHandle, CFURLSessionOptionCAINFO, UnsafeMutablePointer(mutating: pathPtr)).asError()
281+
}
280282
return
281283
}
282284
#endif

0 commit comments

Comments
 (0)