diff options
author | Greg Hazel <ghazel@gmail.com> | 2018-02-11 16:28:58 -0800 |
---|---|---|
committer | Azat Khuzhin <a3at.mail@gmail.com> | 2018-04-24 02:29:17 +0300 |
commit | 367cd9e5c2b8e3f9b8dbed40bfe8a0ed79285c36 (patch) | |
tree | 2ad76775b014805c91b543c8111d31b6c419aa00 /bufferevent-internal.h | |
parent | a3d8f2e09302536c6c0ffc3ccb1fc6f43b51dc4f (diff) | |
download | libevent-367cd9e5c2b8e3f9b8dbed40bfe8a0ed79285c36.tar.gz |
Fix evhttp_connection_get_addr() fox incomming http connections
Install conn_address of the bufferevent on incomping http connections
(even though this is kind of subsytem violation, so let's fix it in a
simplest way and thinkg about long-term solution).
Fixes: #510
Closes: #595 (pick)
Diffstat (limited to 'bufferevent-internal.h')
-rw-r--r-- | bufferevent-internal.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/bufferevent-internal.h b/bufferevent-internal.h index f79e74d3..c3f6b60b 100644 --- a/bufferevent-internal.h +++ b/bufferevent-internal.h @@ -444,6 +444,15 @@ EVENT2_EXPORT_SYMBOL const struct sockaddr* bufferevent_socket_get_conn_address_(struct bufferevent *bev); +EVENT2_EXPORT_SYMBOL +void +bufferevent_socket_set_conn_address_fd_(struct bufferevent *bev, int fd); + +EVENT2_EXPORT_SYMBOL +void +bufferevent_socket_set_conn_address_(struct bufferevent *bev, struct sockaddr *addr, size_t addrlen); + + /** Internal use: We have just successfully read data into an inbuf, so * reset the read timeout (if any). */ #define BEV_RESET_GENERIC_READ_TIMEOUT(bev) \ |