diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-13 07:39:57 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-13 07:39:57 +0000 |
commit | aafdfa61bb0af95e98ca825d1f7839801c22d434 (patch) | |
tree | b792417ed6c2f7764f816aecd177e46b1baad149 /src/os_unix.c | |
parent | Adding debian version 2:9.1.0016-1. (diff) | |
download | vim-aafdfa61bb0af95e98ca825d1f7839801c22d434.tar.xz vim-aafdfa61bb0af95e98ca825d1f7839801c22d434.zip |
Merging upstream version 2:9.1.0199.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | src/os_unix.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/os_unix.c b/src/os_unix.c index af8f006..e98911e 100644 --- a/src/os_unix.c +++ b/src/os_unix.c @@ -2320,12 +2320,11 @@ mch_settitle(char_u *title, char_u *icon) #ifdef FEAT_X11 if (get_x11_windis() == OK) type = 1; -#else -# if defined(FEAT_GUI_PHOTON) \ +#endif +#if defined(FEAT_GUI_PHOTON) \ || defined(FEAT_GUI_GTK) || defined(FEAT_GUI_HAIKU) if (gui.in_use) type = 1; -# endif #endif /* @@ -3049,7 +3048,7 @@ mch_copy_sec(char_u *from_file, char_u *to_file) size = listxattr((char *)from_file, NULL, 0); // not supported or no attributes to copy - if (errno == ENOTSUP || size == 0) + if (size <= 0) return; for (index = 0 ; index < (int)(sizeof(smack_copied_attributes) @@ -3113,8 +3112,8 @@ mch_copy_sec(char_u *from_file, char_u *to_file) mch_copy_xattr(char_u *from_file, char_u *to_file) { char *xattr_buf; - size_t size; - size_t tsize; + ssize_t size; + ssize_t tsize; ssize_t keylen, vallen, max_vallen = 0; char *key; char *val = NULL; @@ -3126,7 +3125,7 @@ mch_copy_xattr(char_u *from_file, char_u *to_file) // get the length of the extended attributes size = listxattr((char *)from_file, NULL, 0); // not supported or no attributes to copy - if (errno == ENOTSUP || size == 0) + if (size <= 0) return; xattr_buf = (char*)alloc(size); if (xattr_buf == NULL) |