aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--doc/chapters/hellobrowser.inc13
-rw-r--r--doc/microhttpd-tutorial.texi8
3 files changed, 16 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index e6aeb577..5474e8e2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
1Fri Nov 4 10:03:00 CET 2011
2 Small updates to the tutorial. -CG
3
1Thu Nov 3 10:14:59 CET 2011 4Thu Nov 3 10:14:59 CET 2011
2 shutdown(RDWR) fails on OS X after shutdown(RD), so only use 5 shutdown(RDWR) fails on OS X after shutdown(RD), so only use
3 shutdown(WR) if we already closed the socket for reading (otherwise 6 shutdown(WR) if we already closed the socket for reading (otherwise
diff --git a/doc/chapters/hellobrowser.inc b/doc/chapters/hellobrowser.inc
index 3c77c806..58597786 100644
--- a/doc/chapters/hellobrowser.inc
+++ b/doc/chapters/hellobrowser.inc
@@ -155,12 +155,17 @@ implemented by checking if the parameter @code{method} equals the string "GET" a
155@code{MHD_NO} if not so. 155@code{MHD_NO} if not so.
156 156
157Secondly, the above practice of queuing a response upon the first call of the callback function 157Secondly, the above practice of queuing a response upon the first call of the callback function
158brings with it some limitations. This is because the content of the message body will not be 158brings with it some limitations. This is because the content of the message body will not be
159received if a response is queued in the first iteration. Furthermore, the connection will be closed 159received if a response is queued in the first iteration. Furthermore, the connection will be closed
160right after the response has been transferred then. 160right after the response has been transferred then. This is typically not what you want as it
161disables HTTP pipelining. The correct approach is to simply not queue a message on the first
162callback unless there is an error. The @code{void**} argument to the callback provides a location
163for storing information about the history of the connection; for the first call, the pointer
164will point to NULL. A simplistic way to differenciate the first call from others is to check
165if the pointer is NULL and set it to a non-NULL value during the first call.
161 166
162Both of these issues you will find addressed in the official @code{minimal_example.c} residing in 167Both of these issues you will find addressed in the official @code{minimal_example.c} residing in
163the @code{src/examples} directory of the @emph{MHD} package. The source code of this 168the @code{src/examples} directory of the @emph{MHD} package. The source code of this
164program should look very familiar to you by now and easy to understand. 169program should look very familiar to you by now and easy to understand.
165 170
166For our example, the @code{must_copy} and @code{must_free} parameter at the response construction 171For our example, the @code{must_copy} and @code{must_free} parameter at the response construction
diff --git a/doc/microhttpd-tutorial.texi b/doc/microhttpd-tutorial.texi
index 020b1e2a..1dc64daa 100644
--- a/doc/microhttpd-tutorial.texi
+++ b/doc/microhttpd-tutorial.texi
@@ -1,10 +1,10 @@
1\input texinfo @c -*-texinfo-*- 1\input texinfo @c -*-texinfo-*-
2@finalout 2@finalout
3@setfilename microhttpd-tutorial.info 3@setfilename microhttpd-tutorial.info
4@set UPDATED 28 Feb 2010 4@set UPDATED 2 Nov 2011
5@set UPDATED-MONTH Feb 2010 5@set UPDATED-MONTH Nov 2011
6@set EDITION 0.9.8 6@set EDITION 0.9.16
7@set VERSION 0.9.8 7@set VERSION 0.9.16
8@settitle A tutorial for GNU libmicrohttpd 8@settitle A tutorial for GNU libmicrohttpd
9 9
10@dircategory GNU Libraries 10@dircategory GNU Libraries