Hi!
I've fixed it in SVN 23236. The page was stack-allocated, in which case
MUST_COPY instead of PERSISTENT must be used in the option to create the
response.
Happy hacking!
Christian
On 08/14/2012 08:06 PM, [email protected] wrote:
Hey Christian,
Thanks for your quick reply!
I think the error has to do with how sprintf is being used. If you pass a
const char* to send_page all goes well. I created a C++ version using
std::string and that works fine too.
Cheers,
MS
On 14 août 2012, at 19:18, Christian Grothoff<[email protected]> wrote:
Dear Mike,
I've added the missing #includes to make all examples compile without warnings
on my system.
I've also been able to reproduce your error with the largepost.c example. I'll
try to look into it more later tonight (as it is not obvious to me what is
wrong).
Happy hacking!
Christian
On 08/14/2012 05:40 PM, [email protected] wrote:
Hey all,
I've been stepping through all the tutorials and running them from Google
Chrome using localhost:8888. Everything works well until I get to largepost.c,
which produces strange results instead of displaying the contents of askpage.
Is anyone else having this issue? I could step through the example to try to
find the cause but I'm hoping that someone more conversant in libmicrohttpd
than I can spot it right away.
Also, one suggestion for the tutorials - it'd be great if all the right header
files could be included in the tutorials so that they work out of the box.
Both simplepost.c and largepost.c, for example, need stdlib.h, stdio.h and
string.h to compile w/ no errors or warnings.
Cheers,
MS