diff options
| author | 2015-07-18 22:33:46 +0000 | |
|---|---|---|
| committer | 2015-07-18 22:33:46 +0000 | |
| commit | 5edb47cb1a80d1f13daf331eb009ea4d70796f34 (patch) | |
| tree | 9f16a44fb4e07c1a3db1534a81aa1f88737ee5da /usr.sbin/syslogd/evbuffer_tls.c | |
| parent | Remove repeated code in dtls1_get_record. (diff) | |
| download | wireguard-openbsd-5edb47cb1a80d1f13daf331eb009ea4d70796f34.tar.xz wireguard-openbsd-5edb47cb1a80d1f13daf331eb009ea4d70796f34.zip | |
As libtls previously did not set SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER,
syslogd had to drop messages after tls_write() returned
TLS_{READ,WRITE}_AGAIN. Now after libtls has been fixed, remove
the workaround. Messages are stored in the libevent write buffer
as we can safely do a realloc(3) now.
OK reyk@
Diffstat (limited to 'usr.sbin/syslogd/evbuffer_tls.c')
| -rw-r--r-- | usr.sbin/syslogd/evbuffer_tls.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/usr.sbin/syslogd/evbuffer_tls.c b/usr.sbin/syslogd/evbuffer_tls.c index 6c164bdf67c..4514e0c14e8 100644 --- a/usr.sbin/syslogd/evbuffer_tls.c +++ b/usr.sbin/syslogd/evbuffer_tls.c @@ -1,4 +1,4 @@ -/* $OpenBSD: evbuffer_tls.c,v 1.4 2015/07/06 16:12:16 millert Exp $ */ +/* $OpenBSD: evbuffer_tls.c,v 1.5 2015/07/18 22:33:46 bluhm Exp $ */ /* * Copyright (c) 2002-2004 Niels Provos <provos@citi.umich.edu> @@ -185,7 +185,6 @@ buffertls_writecb(int fd, short event, void *arg) if (res <= 0) goto error; } - buftls->bt_flags &= ~BT_WRITE_AGAIN; event_set(&bufev->ev_write, fd, EV_WRITE, buffertls_writecb, buftls); if (EVBUFFER_LENGTH(bufev->output) != 0) @@ -202,7 +201,6 @@ buffertls_writecb(int fd, short event, void *arg) return; reschedule: - buftls->bt_flags |= BT_WRITE_AGAIN; if (EVBUFFER_LENGTH(bufev->output) != 0) bufferevent_add(&bufev->ev_write, bufev->timeout_write); return; @@ -277,7 +275,6 @@ buffertls_set(struct buffertls *buftls, struct bufferevent *bufev, event_set(&bufev->ev_write, fd, EV_WRITE, buffertls_writecb, buftls); buftls->bt_bufev = bufev; buftls->bt_ctx = ctx; - buftls->bt_flags = 0; } void |
