comparison src/macros.h @ 21640:e7801d132dcb v8.2.1370

patch 8.2.1370: MS-Windows: warning for using fstat() with stat_T Commit: https://github.com/vim/vim/commit/c753478b82613df37b145764e27f5514542edb97 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Aug 5 12:10:50 2020 +0200 patch 8.2.1370: MS-Windows: warning for using fstat() with stat_T Problem: MS-Windows: warning for using fstat() with stat_T. Solution: use _fstat64() if available. (Naruhiko Nishino, closes https://github.com/vim/vim/issues/6625)
author Bram Moolenaar <Bram@vim.org>
date Wed, 05 Aug 2020 12:15:04 +0200
parents 097f5b5c907b
children bdda90ed5f6c
comparison
equal deleted inserted replaced
21639:651e12be4670 21640:e7801d132dcb
164 # define mch_rmdir(n) rmdir(vms_fixfilename(n)) 164 # define mch_rmdir(n) rmdir(vms_fixfilename(n))
165 #else 165 #else
166 # ifndef MSWIN 166 # ifndef MSWIN
167 # define mch_access(n, p) access((n), (p)) 167 # define mch_access(n, p) access((n), (p))
168 # endif 168 # endif
169 # define mch_fstat(n, p) fstat((n), (p)) 169
170 // Use 64-bit fstat function if available.
171 // NOTE: This condition is the same as for the stat_T type.
172 # if (defined(_MSC_VER) && (_MSC_VER >= 1300)) || defined(__MINGW32__)
173 # define mch_fstat(n, p) _fstat64((n), (p))
174 # else
175 # define mch_fstat(n, p) fstat((n), (p))
176 # endif
177
170 # ifdef MSWIN // has its own mch_stat() function 178 # ifdef MSWIN // has its own mch_stat() function
171 # define mch_stat(n, p) vim_stat((n), (p)) 179 # define mch_stat(n, p) vim_stat((n), (p))
172 # else 180 # else
173 # ifdef STAT_IGNORES_SLASH 181 # ifdef STAT_IGNORES_SLASH
174 # define mch_stat(n, p) vim_stat((n), (p)) 182 # define mch_stat(n, p) vim_stat((n), (p))