summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--opacket.h4
-rw-r--r--packet.c23
-rw-r--r--packet.h3
3 files changed, 3 insertions, 27 deletions
diff --git a/opacket.h b/opacket.h
index b2c2e7f6a..f92fe586e 100644
--- a/opacket.h
+++ b/opacket.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: opacket.h,v 1.12 2017/10/20 01:56:39 djm Exp $ */ 1/* $OpenBSD: opacket.h,v 1.13 2018/07/06 09:03:02 sf Exp $ */
2#ifndef _OPACKET_H 2#ifndef _OPACKET_H
3/* Written by Markus Friedl. Placed in the public domain. */ 3/* Written by Markus Friedl. Placed in the public domain. */
4 4
@@ -59,8 +59,6 @@ void packet_read_expect(int expected_type);
59 ssh_packet_set_protocol_flags(active_state, (protocol_flags)) 59 ssh_packet_set_protocol_flags(active_state, (protocol_flags))
60#define packet_get_protocol_flags() \ 60#define packet_get_protocol_flags() \
61 ssh_packet_get_protocol_flags(active_state) 61 ssh_packet_get_protocol_flags(active_state)
62#define packet_start_compression(level) \
63 ssh_packet_start_compression(active_state, (level))
64#define packet_start(type) \ 62#define packet_start(type) \
65 ssh_packet_start(active_state, (type)) 63 ssh_packet_start(active_state, (type))
66#define packet_put_char(value) \ 64#define packet_put_char(value) \
diff --git a/packet.c b/packet.c
index ab9a391b5..4da9f52b6 100644
--- a/packet.c
+++ b/packet.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: packet.c,v 1.271 2018/06/01 04:05:29 djm Exp $ */ 1/* $OpenBSD: packet.c,v 1.272 2018/07/06 09:03:02 sf Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -147,12 +147,6 @@ struct session_state {
147 int compression_in_failures; 147 int compression_in_failures;
148 int compression_out_failures; 148 int compression_out_failures;
149 149
150 /*
151 * Flag indicating whether packet compression/decompression is
152 * enabled.
153 */
154 int packet_compression;
155
156 /* default maximum packet size */ 150 /* default maximum packet size */
157 u_int max_packet_size; 151 u_int max_packet_size;
158 152
@@ -717,21 +711,6 @@ start_compression_in(struct ssh *ssh)
717 return 0; 711 return 0;
718} 712}
719 713
720int
721ssh_packet_start_compression(struct ssh *ssh, int level)
722{
723 int r;
724
725 if (ssh->state->packet_compression)
726 return SSH_ERR_INTERNAL_ERROR;
727 ssh->state->packet_compression = 1;
728 if ((r = ssh_packet_init_compression(ssh)) != 0 ||
729 (r = start_compression_in(ssh)) != 0 ||
730 (r = start_compression_out(ssh, level)) != 0)
731 return r;
732 return 0;
733}
734
735/* XXX remove need for separate compression buffer */ 714/* XXX remove need for separate compression buffer */
736static int 715static int
737compress_buffer(struct ssh *ssh, struct sshbuf *in, struct sshbuf *out) 716compress_buffer(struct ssh *ssh, struct sshbuf *in, struct sshbuf *out)
diff --git a/packet.h b/packet.h
index a2ece6786..bf9aebdb2 100644
--- a/packet.h
+++ b/packet.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: packet.h,v 1.84 2017/12/10 05:55:29 dtucker Exp $ */ 1/* $OpenBSD: packet.h,v 1.85 2018/07/06 09:03:02 sf Exp $ */
2 2
3/* 3/*
4 * Author: Tatu Ylonen <ylo@cs.hut.fi> 4 * Author: Tatu Ylonen <ylo@cs.hut.fi>
@@ -107,7 +107,6 @@ void ssh_clear_newkeys(struct ssh *, int);
107int ssh_packet_is_rekeying(struct ssh *); 107int ssh_packet_is_rekeying(struct ssh *);
108void ssh_packet_set_protocol_flags(struct ssh *, u_int); 108void ssh_packet_set_protocol_flags(struct ssh *, u_int);
109u_int ssh_packet_get_protocol_flags(struct ssh *); 109u_int ssh_packet_get_protocol_flags(struct ssh *);
110int ssh_packet_start_compression(struct ssh *, int);
111void ssh_packet_set_tos(struct ssh *, int); 110void ssh_packet_set_tos(struct ssh *, int);
112void ssh_packet_set_interactive(struct ssh *, int, int, int); 111void ssh_packet_set_interactive(struct ssh *, int, int, int);
113int ssh_packet_is_interactive(struct ssh *); 112int ssh_packet_is_interactive(struct ssh *);