Fix channel

This commit is contained in:
Kazuki Sakamoto
2016-05-07 00:28:57 -07:00
parent b31f06a1ea
commit f0ba2aaec3
3 changed files with 10 additions and 2 deletions
+1 -2
View File
@@ -3416,6 +3416,7 @@ static id evalExprCocoa(NSString * expr, NSString ** errstr)
- (void)dealloc
{
CFSocketInvalidate(socket);
CFRunLoopSourceInvalidate(runLoopSource);
CFRelease(runLoopSource);
CFRelease(socket);
@@ -3459,9 +3460,7 @@ static void socketReadCallback(CFSocketRef s,
- (void)read
{
#ifdef FEAT_CHANNEL
channel_read(channel, part, "MMChannel_read");
#endif
}
@end
+6
View File
@@ -54,7 +54,9 @@
# define fd_close(sd) close(sd)
#endif
#ifndef FEAT_GUI_MACVIM
static void channel_read(channel_T *channel, int part, char *func);
#endif
/* Whether a redraw is needed for appending a line to a buffer. */
static int channel_need_redraw = FALSE;
@@ -2824,7 +2826,11 @@ channel_close_on_error(channel_T *channel, char *func)
* "part" is PART_SOCK, PART_OUT or PART_ERR.
* The data is put in the read queue.
*/
#ifndef FEAT_GUI_MACVIM
static void
#else
void
#endif
channel_read(channel_T *channel, int part, char *func)
{
static char_u *buf = NULL;
+3
View File
@@ -60,4 +60,7 @@ job_T *job_start(typval_T *argvars);
char *job_status(job_T *job);
void job_info(job_T *job, dict_T *dict);
int job_stop(job_T *job, typval_T *argvars);
#ifdef FEAT_GUI_MACVIM
void channel_read(channel_T *channel, int part, char *func);
#endif
/* vim: set ft=c : */