Skip to content

Commit

Permalink
review fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
hyp committed Dec 12, 2024
1 parent 70ce513 commit de4bb96
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
11 changes: 3 additions & 8 deletions Sources/CoreFoundation/internalInclude/CoreFoundation_Prefix.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,6 @@ typedef char * Class;
#include <pthread.h>
#endif

#if TARGET_OS_ANDROID
#define HAVE_STRLCPY 1
#define HAVE_STRLCAT 1
#endif

#if TARGET_OS_WIN32
#define BOOL WINDOWS_BOOL

Expand Down Expand Up @@ -205,9 +200,9 @@ static dispatch_queue_t __ ## PREFIX ## Queue(void) { \
#endif

// We know some things (Darwin, WASI, Glibc >= 2.38) have strlcpy/strlcat
#if TARGET_OS_MAC || TARGET_OS_WASI \
|| (defined(__GLIBC__) && \
((__GLIBC_MAJOR__ == 2 && __GLIBC_MINOR__ >= 38) \
#if TARGET_OS_MAC || TARGET_OS_WASI || TARGET_OS_ANDROID \
|| (defined(__GLIBC__) && \
((__GLIBC_MAJOR__ == 2 && __GLIBC_MINOR__ >= 38) \
|| __GLIBC_MAJOR__ > 2))
#define HAVE_STRLCPY 1
#define HAVE_STRLCAT 1
Expand Down
2 changes: 1 addition & 1 deletion Sources/Foundation/Process.swift
Original file line number Diff line number Diff line change
Expand Up @@ -938,7 +938,7 @@ open class Process: NSObject, @unchecked Sendable {
useFallbackChdir = false
}

#if canImport(Darwin) || os(Android) || os(OpenBSD)
#if canImport(Darwin) || os(OpenBSD)
var spawnAttrs: posix_spawnattr_t? = nil
#else
var spawnAttrs: posix_spawnattr_t = posix_spawnattr_t()
Expand Down

0 comments on commit de4bb96

Please sign in to comment.