forked from aniani/vim
patch 8.0.1286: occasional crash when using a channel
Problem: Occasional crash when using a channel. (Marek) Solution: Decrement reference count later. (closes #2315)
This commit is contained in:
@@ -2898,8 +2898,6 @@ channel_close(channel_T *channel, int invoke_close_cb)
|
|||||||
channel->ch_close_cb = NULL;
|
channel->ch_close_cb = NULL;
|
||||||
channel->ch_close_partial = NULL;
|
channel->ch_close_partial = NULL;
|
||||||
|
|
||||||
--channel->ch_refcount;
|
|
||||||
|
|
||||||
if (channel_need_redraw)
|
if (channel_need_redraw)
|
||||||
{
|
{
|
||||||
channel_need_redraw = FALSE;
|
channel_need_redraw = FALSE;
|
||||||
@@ -2910,6 +2908,8 @@ channel_close(channel_T *channel, int invoke_close_cb)
|
|||||||
/* any remaining messages are useless now */
|
/* any remaining messages are useless now */
|
||||||
for (part = PART_SOCK; part < PART_IN; ++part)
|
for (part = PART_SOCK; part < PART_IN; ++part)
|
||||||
drop_messages(channel, part);
|
drop_messages(channel, part);
|
||||||
|
|
||||||
|
--channel->ch_refcount;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -761,6 +761,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1286,
|
||||||
/**/
|
/**/
|
||||||
1285,
|
1285,
|
||||||
/**/
|
/**/
|
||||||
|
|||||||
Reference in New Issue
Block a user