libmicrohttpd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [libmicrohttpd] MHD_RESPMEM_PERSISTENT


From: Christian Grothoff
Subject: Re: [libmicrohttpd] MHD_RESPMEM_PERSISTENT
Date: Wed, 25 Jan 2017 13:09:47 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.4.0

On 01/25/2017 05:01 AM, Mark Wagner wrote:
>  As far as I'm aware, there's no way to
> know when the library is actually done with the response object.

Well, after you call MHD_stop_daemon(), we're definitively done ;-).

But yes, you are totally right in the rest of your analysis.

> It may be safe to free the buffer when the
> MHD_RequestCompletedCallback is called, but the documentation is
> unclear about this.

Well, that's because you can share the same response object across
multiple connections, in which case the completed callback for one
connection is not helpful for the next one.  Otherwise, yes, this ought
to be safe, but as you said, this is not how PERSISTENT is supposed to
be used.

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]