Mercurial > vim
comparison src/ui.c @ 24196:1040b294bfd3 v8.2.2639
patch 8.2.2639: build failure when fsync() is not available
Commit: https://github.com/vim/vim/commit/5ea79a2599d35f75e1ae8a75d2711c754c4cb7c4
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Mar 22 16:45:35 2021 +0100
patch 8.2.2639: build failure when fsync() is not available
Problem: Build failure when fsync() is not available.
Solution: Add #ifdef.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 22 Mar 2021 17:00:03 +0100 |
parents | 9f64c420f280 |
children | fdc6a7769045 |
comparison
equal
deleted
inserted
replaced
24195:2e1ba2b9a8c8 | 24196:1040b294bfd3 |
---|---|
48 s = tofree; | 48 s = tofree; |
49 } | 49 } |
50 # endif | 50 # endif |
51 | 51 |
52 mch_write(s, len); | 52 mch_write(s, len); |
53 # if defined(HAVE_FSYNC) | |
53 if (console && s[len - 1] == '\n') | 54 if (console && s[len - 1] == '\n') |
54 fsync(1); | 55 vim_fsync(1); |
56 # endif | |
55 | 57 |
56 # if !defined(MSWIN) | 58 # if !defined(MSWIN) |
57 if (output_conv.vc_type != CONV_NONE) | 59 if (output_conv.vc_type != CONV_NONE) |
58 vim_free(tofree); | 60 vim_free(tofree); |
59 # endif | 61 # endif |