2011-03-02 10:06:04 -05:00
|
|
|
$OpenBSD: patch-ii_c,v 1.2 2011/03/02 15:06:04 jasper Exp $
|
|
|
|
--- ii.c.orig Mon Jan 31 21:47:08 2011
|
|
|
|
+++ ii.c Wed Mar 2 16:04:30 2011
|
|
|
|
@@ -395,8 +395,9 @@ static int read_line(int fd, size_t res_len, char *buf
|
2009-03-26 13:38:26 -04:00
|
|
|
static void handle_channels_input(Channel *c) {
|
|
|
|
static char buf[PIPE_BUF];
|
|
|
|
if(read_line(c->fd, PIPE_BUF, buf) == -1) {
|
|
|
|
+ int fd;
|
|
|
|
close(c->fd);
|
|
|
|
- int fd = open_channel(c->name);
|
|
|
|
+ fd = open_channel(c->name);
|
|
|
|
if(fd != -1)
|
|
|
|
c->fd = fd;
|
|
|
|
else
|