[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[Libevent-users] evhttp_request_own



Hi!

I have a hard time to understand how `evhttp_request_own()` should be
used. I am trying to implement a websocket entry point. Therefore, once
I have parsed the request headers, I call `evhttp_request_own()` and I
do the upgrade myself. When I don't need the request anymore, I use
`evhttp_request_free()`.

However, when the connection is closed, I see that
`evhttp_request_free()` is called again. So, it seems I just don't need
to own the request and can just do whatever I want with it and not free
it myself? I already modify the callbacks to put my own.

The documentation is not quite clear on this.
-- 
Write clearly - don't sacrifice clarity for "efficiency".
            - The Elements of Programming Style (Kernighan & Plauger)
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users    in the body.