Hi
Attached patch fixes this compilation warning with vim-7.4.1318:
os_unix.c:5126:8: warning: ‘channel’ may be used uninitialized in this
function [-Wmaybe-uninitialized]
if (channel != NULL)
^
It's a real bug, since there is a path where channel_free(channel);
could be called on an uninitialized channel variable.
Regards
Dominique
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.
diff --git a/src/os_unix.c b/src/os_unix.c
index 65a4b92..ec7d6c1 100644
--- a/src/os_unix.c
+++ b/src/os_unix.c
@@ -5043,7 +5043,7 @@ mch_start_job(char **argv, job_T *job)
int fd_in[2]; /* for stdin */
int fd_out[2]; /* for stdout */
int fd_err[2]; /* for stderr */
- channel_T *channel;
+ channel_T *channel = NULL;
/* default is to fail */
job->jv_status = JOB_FAILED;