macOS: drop support for macOS < 10.9

PR-URL: https://github.com/libuv/libuv/pull/966
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Fedor Indutny <fedor@indutny.com>
This commit is contained in:
Saúl Ibarra Corretgé 2016-08-03 10:31:21 +01:00
parent d7f65293c0
commit 46dbdd0f97
4 changed files with 2 additions and 27 deletions

View File

@ -231,7 +231,7 @@ Studio license.
Linux using the GCC toolchain.
OS X using the GCC or XCode toolchain.
macOS >= 10.9 using the GCC or XCode toolchain.
Solaris 121 and later using GCC toolchain.

View File

@ -336,7 +336,7 @@ done:
}
#if defined(__OpenBSD__) || (defined(__APPLE__) && !defined(MAC_OS_X_VERSION_10_8))
#if defined(__OpenBSD__)
static int uv__fs_scandir_filter(uv__dirent_t* dent) {
#else
static int uv__fs_scandir_filter(const uv__dirent_t* dent) {

View File

@ -267,11 +267,9 @@ static void uv__fsevents_event_cb(ConstFSEventStreamRef streamRef,
}
}
#ifdef MAC_OS_X_VERSION_10_7
/* Ignore events with path equal to directory itself */
if (len == 0)
continue;
#endif /* MAC_OS_X_VERSION_10_7 */
/* Do not emit events from subdirectories (without option set) */
if ((handle->cf_flags & UV_FS_EVENT_RECURSIVE) == 0 && *path != 0) {
@ -280,11 +278,6 @@ static void uv__fsevents_event_cb(ConstFSEventStreamRef streamRef,
continue;
}
#ifndef MAC_OS_X_VERSION_10_7
path = "";
len = 0;
#endif /* MAC_OS_X_VERSION_10_7 */
event = uv__malloc(sizeof(*event) + len);
if (event == NULL)
break;

View File

@ -275,24 +275,6 @@ int uv__fsevents_init(uv_fs_event_t* handle);
int uv__fsevents_close(uv_fs_event_t* handle);
void uv__fsevents_loop_delete(uv_loop_t* loop);
/* OSX < 10.7 has no file events, polyfill them */
#ifndef MAC_OS_X_VERSION_10_7
static const int kFSEventStreamCreateFlagFileEvents = 0x00000010;
static const int kFSEventStreamEventFlagItemCreated = 0x00000100;
static const int kFSEventStreamEventFlagItemRemoved = 0x00000200;
static const int kFSEventStreamEventFlagItemInodeMetaMod = 0x00000400;
static const int kFSEventStreamEventFlagItemRenamed = 0x00000800;
static const int kFSEventStreamEventFlagItemModified = 0x00001000;
static const int kFSEventStreamEventFlagItemFinderInfoMod = 0x00002000;
static const int kFSEventStreamEventFlagItemChangeOwner = 0x00004000;
static const int kFSEventStreamEventFlagItemXattrMod = 0x00008000;
static const int kFSEventStreamEventFlagItemIsFile = 0x00010000;
static const int kFSEventStreamEventFlagItemIsDir = 0x00020000;
static const int kFSEventStreamEventFlagItemIsSymlink = 0x00040000;
#endif /* __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070 */
#endif /* defined(__APPLE__) */
UV_UNUSED(static void uv__req_init(uv_loop_t* loop,