コード例 #1
0
ファイル: opacket.c プロジェクト: jaredmcneill/netbsd-src
void
packet_read_expect(int expected_type)
{
	int r;

	if ((r = ssh_packet_read_expect(active_state, expected_type)) != 0)
		sshpkt_fatal(active_state, __func__, r);
}
コード例 #2
0
ファイル: opacket.c プロジェクト: jaredmcneill/netbsd-src
void
packet_write_wait(void)
{
	int r;

	if ((r = ssh_packet_write_wait(active_state)) < 0)
		sshpkt_fatal(active_state, __func__, r);
}
コード例 #3
0
ファイル: opacket.c プロジェクト: jaredmcneill/netbsd-src
void
packet_process_incoming(const char *buf, u_int len)
{
	int r;

	if ((r = ssh_packet_process_incoming(active_state, buf, len)) != 0)
		sshpkt_fatal(active_state, __func__, r);
}
コード例 #4
0
void
packet_write_poll(void)
{
	int r;

	if ((r = ssh_packet_write_poll(active_state)) != 0)
		sshpkt_fatal(active_state, __func__, r);
}
コード例 #5
0
ファイル: dispatch.c プロジェクト: mfriedl/openssh
void
ssh_dispatch_run_fatal(struct ssh *ssh, int mode, volatile sig_atomic_t *done)
{
	int r;

	if ((r = ssh_dispatch_run(ssh, mode, done)) != 0)
		sshpkt_fatal(ssh, r, "%s", __func__);
}
コード例 #6
0
ファイル: opacket.c プロジェクト: jaredmcneill/netbsd-src
int
packet_write_poll(void)
{
	int r;

	if ((r = ssh_packet_write_poll(active_state)) < 0)
		sshpkt_fatal(active_state, __func__, r);
	return r;
}
コード例 #7
0
ファイル: opacket.c プロジェクト: jaredmcneill/netbsd-src
int
packet_read_poll_seqnr(u_int32_t *seqnr)
{
	u_char type;
	int r;

	if ((r = ssh_packet_read_poll_seqnr(active_state, &type, seqnr)))
		sshpkt_fatal(active_state, __func__, r);
	return type;
}
コード例 #8
0
ファイル: dispatch.c プロジェクト: mfriedl/openssh
int
dispatch_protocol_error(int type, u_int32_t seq, struct ssh *ssh)
{
	int r;

	logit("dispatch_protocol_error: type %d seq %u", type, seq);
	if ((r = sshpkt_start(ssh, SSH2_MSG_UNIMPLEMENTED)) != 0 ||
	    (r = sshpkt_put_u32(ssh, seq)) != 0 ||
	    (r = sshpkt_send(ssh)) != 0 ||
	    (r = ssh_packet_write_wait(ssh)) != 0)
		sshpkt_fatal(ssh, r, "%s", __func__);
	return 0;
}