diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-09-05 23:32:38 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-09-05 23:32:38 +0200 |
commit | 1b9f9d315f137cc883c7aecd39f3df329b7f9085 (patch) | |
tree | e400e8eb6d43061f32a009206e623f1664493b20 /src | |
parent | 28550b74bb4373417eb6fbf132bd4211b7b92afa (diff) | |
download | vim-git-1b9f9d315f137cc883c7aecd39f3df329b7f9085.tar.gz |
patch 8.0.1064: Coverity warns for leaking resourcev8.0.1064
Problem: Coverity warns for leaking resource.
Solution: Free pty_master_fd on failure.
Diffstat (limited to 'src')
-rw-r--r-- | src/os_unix.c | 3 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/os_unix.c b/src/os_unix.c index 57ea4d945..1ec59fcdc 100644 --- a/src/os_unix.c +++ b/src/os_unix.c @@ -5692,7 +5692,10 @@ mch_create_pty_channel(job_T *job, jobopt_T *options) channel = add_channel(); if (channel == NULL) + { + close(pty_master_fd); return FAIL; + } job->jv_channel = channel; /* ch_refcount was set by add_channel() */ channel->ch_keep_open = TRUE; diff --git a/src/version.c b/src/version.c index 6be7b8255..6a0fa7b61 100644 --- a/src/version.c +++ b/src/version.c @@ -770,6 +770,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1064, +/**/ 1063, /**/ 1062, |