diff options
author | Martin Hunt <hunt@redhat.com> | 2001-12-18 18:54:18 +0000 |
---|---|---|
committer | Martin Hunt <hunt@redhat.com> | 2001-12-18 18:54:18 +0000 |
commit | 67a59bc02d4e7bd331e648efcf1d5a09fe048c56 (patch) | |
tree | f7a7589e3ee71fced1793f90626adb8fff812c23 /gdb/ser-tcp.c | |
parent | f0b79d91cbbaf7e2fc4441aee9b7a1527a18f078 (diff) | |
download | gdb-67a59bc02d4e7bd331e648efcf1d5a09fe048c56.zip gdb-67a59bc02d4e7bd331e648efcf1d5a09fe048c56.tar.gz gdb-67a59bc02d4e7bd331e648efcf1d5a09fe048c56.tar.bz2 |
2001-12-18 Martin M. Hunt <hunt@redhat.com>
* ser-tcp.c (tcp_open): Disable Nagle algorithm which
improves performance in some cases.
Diffstat (limited to 'gdb/ser-tcp.c')
-rw-r--r-- | gdb/ser-tcp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/ser-tcp.c b/gdb/ser-tcp.c index 6a65177..6dc8284 100644 --- a/gdb/ser-tcp.c +++ b/gdb/ser-tcp.c @@ -165,6 +165,11 @@ tcp_open (struct serial *scb, const char *name) tmp = 0; ioctl (scb->fd, FIONBIO, &tmp); + /* Disable Nagle algorithm. Needed in some cases. */ + tmp = 1; + setsockopt (scb->fd, IPPROTO_TCP, TCP_NODELAY, + (char *)&tmp, sizeof (tmp)); + /* If we don't do this, then GDB simply exits when the remote side dies. */ signal (SIGPIPE, SIG_IGN); |