forked from pool/neovim
Matej Cepl
c90bf7d30d
(applied conditionally only on the appropriate distribution), which works around too old version of libuv on Leap 15.* by not using UV_FS_COPYFILE_FICLONE flag to uv_fs_copyfile, and not using uv_stream_get_write_queue_size at all. sr#793088 gh#neovim/neovim#12108 OBS-URL: https://build.opensuse.org/package/show/editors/neovim?expand=0&rev=72
29 lines
904 B
Diff
29 lines
904 B
Diff
--- a/src/nvim/fileio.c
|
|
+++ b/src/nvim/fileio.c
|
|
@@ -62,6 +62,11 @@
|
|
#define BUFSIZE 8192 /* size of normal write buffer */
|
|
#define SMBUFSIZE 256 /* size of emergency write buffer */
|
|
|
|
+// For compatibility with libuv < 1.20.0 (tested on 1.18.0)
|
|
+#ifndef UV_FS_COPYFILE_FICLONE
|
|
+#define UV_FS_COPYFILE_FICLONE 0
|
|
+#endif
|
|
+
|
|
//
|
|
// The autocommands are stored in a list for each event.
|
|
// Autocommands for the same pattern, that are consecutive, are joined
|
|
--- a/src/nvim/event/stream.c
|
|
+++ b/src/nvim/event/stream.c
|
|
@@ -16,6 +16,11 @@
|
|
# include "event/stream.c.generated.h"
|
|
#endif
|
|
|
|
+// For compatbility with libuv < 1.19.0 (tested on 1.18.0)
|
|
+#if UV_VERSION_MINOR < 19
|
|
+#define uv_stream_get_write_queue_size(stream) stream->write_queue_size
|
|
+#endif
|
|
+
|
|
/// Sets the stream associated with `fd` to "blocking" mode.
|
|
///
|
|
/// @return `0` on success, or libuv error code on failure.
|