From eb55e6aa88f5dfef10c86fae5377e1280cf91bf7 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Tue, 1 Jul 2014 19:39:26 +0200 Subject: write_queue: Use EBADF instead of EBABDFD for portability EBADFD is linux specific while EBADF is POSIX. Fix the build on FreeBSD and use EBADF throughout the file. --- src/vty/telnet_interface.c | 2 +- src/vty/vty.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/vty') diff --git a/src/vty/telnet_interface.c b/src/vty/telnet_interface.c index 0a04d158..50b08c8a 100644 --- a/src/vty/telnet_interface.c +++ b/src/vty/telnet_interface.c @@ -120,7 +120,7 @@ static int client_data(struct osmo_fd *fd, unsigned int what) } /* vty might have been closed from vithin vty_read() */ - if (rc == -EBADFD) + if (rc == -EBADF) return rc; if (what & BSC_FD_WRITE) { diff --git a/src/vty/vty.c b/src/vty/vty.c index fc86bdf3..10a323fd 100644 --- a/src/vty/vty.c +++ b/src/vty/vty.c @@ -1434,7 +1434,7 @@ int vty_read(struct vty *vty) /* Check status. */ if (vty->status == VTY_CLOSE) { vty_close(vty); - return -EBADFD; + return -EBADF; } else { vty_event(VTY_WRITE, vty_sock, vty); vty_event(VTY_READ, vty_sock, vty); -- cgit v1.2.3