diff options
Diffstat (limited to 'doc/chapters/hellobrowser.inc')
-rw-r--r-- | doc/chapters/hellobrowser.inc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/chapters/hellobrowser.inc b/doc/chapters/hellobrowser.inc index 65681de2..bfb5166e 100644 --- a/doc/chapters/hellobrowser.inc +++ b/doc/chapters/hellobrowser.inc | |||
@@ -54,7 +54,7 @@ HTTP is a rather strict protocol and the client would certainly consider it "ina | |||
54 | just sent the answer string "as is". Instead, it has to be wrapped with additional information stored in so-called headers and footers. Most of the work in this area is done by the library for us---we | 54 | just sent the answer string "as is". Instead, it has to be wrapped with additional information stored in so-called headers and footers. Most of the work in this area is done by the library for us---we |
55 | just have to ask. Our reply string packed in the necessary layers will be called a "response". | 55 | just have to ask. Our reply string packed in the necessary layers will be called a "response". |
56 | To obtain such a response we hand our data (the reply--string) and its size over to the | 56 | To obtain such a response we hand our data (the reply--string) and its size over to the |
57 | @code{MHD_create_response_from_data} function. The last two parameters basically tell @emph{MHD} | 57 | @code{MHD_create_response_from_buffer} function. The last two parameters basically tell @emph{MHD} |
58 | that we do not want it to dispose the message data for us when it has been sent and there also needs | 58 | that we do not want it to dispose the message data for us when it has been sent and there also needs |
59 | no internal copy to be done because the @emph{constant} string won't change anyway. | 59 | no internal copy to be done because the @emph{constant} string won't change anyway. |
60 | 60 | ||
@@ -62,8 +62,8 @@ no internal copy to be done because the @emph{constant} string won't change anyw | |||
62 | struct MHD_Response *response; | 62 | struct MHD_Response *response; |
63 | int ret; | 63 | int ret; |
64 | 64 | ||
65 | response = MHD_create_response_from_data (strlen (page), | 65 | response = MHD_create_response_from_buffer (strlen (page), |
66 | (void*) page, MHD_NO, MHD_NO); | 66 | (void*) page, MHD_RESPMEM_PERSISTENT); |
67 | 67 | ||
68 | @end verbatim | 68 | @end verbatim |
69 | 69 | ||