Skip to content

Commit c6e4e84

Browse files
committed
Remove upstreamed Foundation patch from devel branch on CI
1 parent b8c955b commit c6e4e84

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

swift-android-foundation-devel.patch

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,3 @@
1-
From 7e0817f4c7dbc748fc70c45c20edd5acc98a34d7
2-
From: Yuta Saito <[email protected]>
3-
Date: Tue, 17 Dec 2024 04:19:39 +0900
4-
Subject: [PATCH] Follow-up fixes to make it work with wasi-libc (#1095)
5-
6-
* Use `futimens` instead of legacy `futimes`
7-
8-
wasi-libc does not provide `futimes` as it is a legacy function.
9-
https://github.com/WebAssembly/wasi-libc/blob/574b88da481569b65a237cb80daf9a2d5aeaf82d/libc-top-half/musl/include/sys/time.h#L34
10-
11-
diff --git a/swift-foundation/Sources/FoundationEssentials/FileManager/FileOperations.swift b/swift-foundation/Sources/FoundationEssentials/FileManager/FileOperations.swift
12-
index ce4de44a..96ee566d 100644
13-
--- a/swift-foundation/Sources/FoundationEssentials/FileManager/FileOperations.swift
14-
+++ b/swift-foundation/Sources/FoundationEssentials/FileManager/FileOperations.swift
15-
@@ -944,11 +944,11 @@ enum _FileOperations {
16-
}
17-
18-
// Copy modification date
19-
- let value = timeval(tv_sec: statInfo.st_mtim.tv_sec, tv_usec: statInfo.st_mtim.tv_nsec / 1000)
20-
+ let value = statInfo.st_mtim
21-
var tv = (value, value)
22-
try withUnsafePointer(to: &tv) {
23-
- try $0.withMemoryRebound(to: timeval.self, capacity: 2) {
24-
- if futimes(dstFD, $0) != 0 {
25-
+ try $0.withMemoryRebound(to: timespec.self, capacity: 2) {
26-
+ if futimens(dstFD, $0) != 0 {
27-
try delegate.throwIfNecessary(errno, srcPath(), dstPath())
28-
}
29-
}
301
commit 4339393f2c1f3bceaf20bc2c25ee828a2e0394aa
312
Author: Alex Lorenz <[email protected]>
323
Date: Thu Dec 12 07:34:34 2024 -0800

0 commit comments

Comments
 (0)