summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--compat.c4
-rw-r--r--compat.h4
-rw-r--r--ttymodes.c13
3 files changed, 15 insertions, 6 deletions
diff --git a/compat.c b/compat.c
index 89b302cc..861e9e21 100644
--- a/compat.c
+++ b/compat.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: compat.c,v 1.105 2018/01/23 05:27:21 djm Exp $ */
+/* $OpenBSD: compat.c,v 1.106 2018/02/16 04:43:11 dtucker Exp $ */
/*
* Copyright (c) 1999, 2000, 2001, 2002 Markus Friedl. All rights reserved.
*
@@ -126,6 +126,8 @@ compat_datafellows(const char *version)
"WinSCP_release_5.7.3,"
"WinSCP_release_5.7.4",
SSH_OLD_DHGEX },
+ { "ConfD-*",
+ SSH_BUG_UTF8TTYMODE },
{ NULL, 0 }
};
diff --git a/compat.h b/compat.h
index 246e6ee4..4fee3495 100644
--- a/compat.h
+++ b/compat.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: compat.h,v 1.50 2018/01/23 05:27:21 djm Exp $ */
+/* $OpenBSD: compat.h,v 1.51 2018/02/16 04:43:11 dtucker Exp $ */
/*
* Copyright (c) 1999, 2000, 2001 Markus Friedl. All rights reserved.
@@ -32,7 +32,7 @@
#define SSH_PROTO_1_PREFERRED 0x02
#define SSH_PROTO_2 0x04
-/* #define unused 0x00000001 */
+#define SSH_BUG_UTF8TTYMODE 0x00000001
/* #define unused 0x00000002 */
/* #define unused 0x00000004 */
/* #define unused 0x00000008 */
diff --git a/ttymodes.c b/ttymodes.c
index 84513963..f9fdb92d 100644
--- a/ttymodes.c
+++ b/ttymodes.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ttymodes.c,v 1.32 2017/04/30 23:26:54 djm Exp $ */
+/* $OpenBSD: ttymodes.c,v 1.33 2018/02/16 04:43:11 dtucker Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -56,6 +56,7 @@
#include "log.h"
#include "compat.h"
#include "buffer.h"
+#include "compat.h"
#define TTY_OP_END 0
/*
@@ -308,9 +309,15 @@ tty_make_modes(int fd, struct termios *tiop)
buffer_put_char(&buf, OP); \
buffer_put_int(&buf, special_char_encode(tio.c_cc[NAME]));
+#define SSH_TTYMODE_IUTF8 42 /* for SSH_BUG_UTF8TTYMODE */
+
#define TTYMODE(NAME, FIELD, OP) \
- buffer_put_char(&buf, OP); \
- buffer_put_int(&buf, ((tio.FIELD & NAME) != 0));
+ if (OP == SSH_TTYMODE_IUTF8 && (datafellows & SSH_BUG_UTF8TTYMODE)) { \
+ debug3("%s: SSH_BUG_UTF8TTYMODE", __func__); \
+ } else { \
+ buffer_put_char(&buf, OP); \
+ buffer_put_int(&buf, ((tio.FIELD & NAME) != 0)); \
+ }
#include "ttymodes.h"