Lines Matching defs:bufev

330 int	 tcpbuf_countmsg(struct bufferevent *bufev);
1214 tls_handshakecb(struct bufferevent *bufev, void *arg)
1238 bufferevent_setcb(bufev, tcp_readcb, NULL, tcp_closecb, p);
1319 tcp_readcb(struct bufferevent *bufev, void *arg)
1325 while (EVBUFFER_LENGTH(bufev->input) > 0) {
1329 len = octet_counting(bufev->input, &msg, 1);
1331 len = non_transparent_framing(bufev->input, &msg);
1347 evbuffer_drain(bufev->input, len);
1350 if (EVBUFFER_LENGTH(bufev->input) >= 5 + 1 + LOG_MAXLINE + 1) {
1351 log_debug(", use %zu bytes", EVBUFFER_LENGTH(bufev->input));
1352 EVBUFFER_DATA(bufev->input)[5 + 1 + LOG_MAXLINE] = '\0';
1353 printline(p->p_hostname, EVBUFFER_DATA(bufev->input));
1354 evbuffer_drain(bufev->input, -1);
1355 } else if (EVBUFFER_LENGTH(bufev->input) > 0)
1356 log_debug(", buffer %zu bytes", EVBUFFER_LENGTH(bufev->input));
1360 tcp_closecb(struct bufferevent *bufev, short event, void *arg)
1403 tcp_dropcb(struct bufferevent *bufev, void *arg)
1411 f->f_un.f_forw.f_loghost, EVBUFFER_LENGTH(bufev->input));
1412 evbuffer_drain(bufev->input, -1);
1416 tcp_writecb(struct bufferevent *bufev, void *arg)
1436 tcp_errorcb(struct bufferevent *bufev, short event, void *arg)
1459 bufferevent_disable(bufev, EV_READ|EV_WRITE);
1468 buf = EVBUFFER_DATA(bufev->output);
1469 end = buf + EVBUFFER_LENGTH(bufev->output);
1470 if (buf < end && !((l = octet_counting(bufev->output, &p, 0)) > 0 &&
1474 evbuffer_drain(bufev->output, p - buf + 1);
1480 evbuffer_drain(bufev->output, -1);
1496 struct bufferevent *bufev = f->f_un.f_forw.f_bufev;
1513 bufferevent_setfd(bufev, s);
1514 bufferevent_setcb(bufev, tcp_dropcb, tcp_writecb, tcp_errorcb, f);
1519 bufferevent_enable(bufev, EV_READ|EV_WRITE);
1542 buffertls_set(&f->f_un.f_forw.f_buftls, bufev,
1554 bufferevent_disable(bufev, EV_READ|EV_WRITE);
1640 tcpbuf_countmsg(struct bufferevent *bufev)
1645 buf = EVBUFFER_DATA(bufev->output);
1646 end = buf + EVBUFFER_LENGTH(bufev->output);