*/
#include "includes.h"
-RCSID("$OpenBSD: channels.c,v 1.151 2001/12/27 20:39:58 markus Exp $");
+RCSID("$OpenBSD: channels.c,v 1.152 2001/12/28 12:14:27 markus Exp $");
#include "ssh.h"
#include "ssh1.h"
}
c->local_window -= data_len;
}
- packet_done();
+ packet_check_eom();
buffer_append(&c->output, data, data_len);
xfree(data);
}
return;
}
data = packet_get_string(&data_len);
- packet_done();
+ packet_check_eom();
if (data_len > c->local_window) {
log("channel %d: rcvd too much extended_data %d, win %d",
c->self, data_len, c->local_window);
Channel *c;
id = packet_get_int();
- packet_done();
+ packet_check_eom();
c = channel_lookup(id);
if (c == NULL)
packet_disconnect("Received ieof for nonexistent channel %d.", id);
Channel *c;
id = packet_get_int();
- packet_done();
+ packet_check_eom();
c = channel_lookup(id);
if (c == NULL)
packet_disconnect("Received close for nonexistent channel %d.", id);
int id = packet_get_int();
Channel *c = channel_lookup(id);
- packet_done();
+ packet_check_eom();
if (c == NULL)
packet_disconnect("Received oclose for nonexistent channel %d.", id);
chan_rcvd_oclose(c);
int id = packet_get_int();
Channel *c = channel_lookup(id);
- packet_done();
+ packet_check_eom();
if (c == NULL)
packet_disconnect("Received close confirmation for "
"out-of-range channel %d.", id);
debug("channel %d: open confirm rwindow %d rmax %d", c->self,
c->remote_window, c->remote_maxpacket);
}
- packet_done();
+ packet_check_eom();
}
static char *
if (lang != NULL)
xfree(lang);
}
- packet_done();
+ packet_check_eom();
/* Free the channel. This will also close the socket. */
channel_free(c);
}
return;
}
adjust = packet_get_int();
- packet_done();
+ packet_check_eom();
debug2("channel %d: rcvd adjust %d", id, adjust);
c->remote_window += adjust;
}
} else {
originator_string = xstrdup("unknown (remote did not supply name)");
}
- packet_done();
+ packet_check_eom();
sock = channel_connect_to(host, host_port);
if (sock != -1) {
c = channel_new("connected socket",
} else {
remote_host = xstrdup("unknown (remote did not supply name)");
}
- packet_done();
+ packet_check_eom();
/* Obtain a connection to the real X display. */
sock = x11_connect_display();
/* Read the remote channel number from the message. */
remote_id = packet_get_int();
- packet_done();
+ packet_check_eom();
/*
* Get a connection to the local authentication agent (this may again