diff options
author | Bram Moolenaar <Bram@vim.org> | 2012-01-10 22:26:17 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2012-01-10 22:26:17 +0100 |
commit | 70b2a56d5a8fd54f3d0707fa77dea86a4bd8195f (patch) | |
tree | 2144b21b49d79de16665fb585daf1e9cf66e85c0 /src/os_unix.c | |
parent | 1f5965b3c4d2b29e167a5dfecdf0ec59fe4c45c0 (diff) | |
download | vim-git-7.3.400.tar.gz |
updated for version 7.3.400v7.3.400
Problem: Compiler warnings for shadowed variables.
Solution: Remove or rename the variables.
Diffstat (limited to 'src/os_unix.c')
-rw-r--r-- | src/os_unix.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/os_unix.c b/src/os_unix.c index cdf5abe7f..30593ef47 100644 --- a/src/os_unix.c +++ b/src/os_unix.c @@ -3884,7 +3884,6 @@ mch_call_shell(cmd, options) char_u *p_shcf_copy = NULL; int i; char_u *p; - char_u *s; int inquote; int pty_master_fd = -1; /* for pty's */ # ifdef FEAT_GUI @@ -3963,6 +3962,8 @@ mch_call_shell(cmd, options) } if (cmd != NULL) { + char_u *s; + if (extra_shell_arg != NULL) argv[argc++] = (char *)extra_shell_arg; @@ -4325,7 +4326,6 @@ mch_call_shell(cmd, options) linenr_T lnum = curbuf->b_op_start.lnum; int written = 0; char_u *lp = ml_get(lnum); - char_u *s; size_t l; close(fromshell_fd); @@ -4339,7 +4339,8 @@ mch_call_shell(cmd, options) len = write(toshell_fd, "", (size_t)1); else { - s = vim_strchr(lp + written, NL); + char_u *s = vim_strchr(lp + written, NL); + len = write(toshell_fd, (char *)lp + written, s == NULL ? l : (size_t)(s - (lp + written))); |