summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2018-07-17 19:02:34 +0200
committerlynxis lazus <lynxis@fe80.eu>2018-07-20 20:40:48 +0000
commitab383e6d27bac1c2627640e7b3aa4f96428fcf5b (patch)
tree5dfe3f59c4aa5f49847e79cb1b21174143affe2d
parent59f4caf4efcbd76478cdd2a1d800c0978144c5ba (diff)
vty: initialize termios before using it
valgrind complains about using unitialised bytes in syscalls. I could imagine this happens when tcgetattr fails to set termios. Change-Id: I9d165911fa3127afa8f836fa5c5c2e14a949474a
-rw-r--r--src/vty/vty.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vty/vty.c b/src/vty/vty.c
index 08258e71..6ca7a154 100644
--- a/src/vty/vty.c
+++ b/src/vty/vty.c
@@ -1506,7 +1506,7 @@ vty_create (int vty_sock, void *priv)
{
struct vty *vty;
- struct termios t;
+ struct termios t = {};
tcgetattr(vty_sock, &t);
cfmakeraw(&t);