summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-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 3357d5a7..cd252ad1 100644
--- a/src/vty/vty.c
+++ b/src/vty/vty.c
@@ -231,7 +231,7 @@ void vty_close(struct vty *vty)
vector_unset(vtyvec, vty->fd);
/* Close socket. */
- if (vty->fd > 0) {
+ if (vty->fd > 0 && vty->fd != fileno(stderr)) {
close(vty->fd);
vty->fd = -1;
}