diff options
author | Aleksey Veresov <aleksey@veresov.pro> | 2020-07-13 08:33:09 +0300 |
---|---|---|
committer | Aleksey Veresov <aleksey@veresov.pro> | 2020-07-13 08:33:09 +0300 |
commit | 2aabe59373c29410c00ae59cd86cb475c961b56c (patch) | |
tree | 43063644a70dee80276cc65b8a0509c154c22473 /examples | |
parent | c452c3dc47bacf1cb4dfd7a8129d62fa8819282e (diff) | |
download | magi-2aabe59373c29410c00ae59cd86cb475c961b56c.tar magi-2aabe59373c29410c00ae59cd86cb475c961b56c.tar.xz magi-2aabe59373c29410c00ae59cd86cb475c961b56c.zip |
magi_response_send, urlenc docs.
Diffstat (limited to 'examples')
-rw-r--r-- | examples/cookie.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/cookie.c b/examples/cookie.c index c64ca0c..7cb5f33 100644 --- a/examples/cookie.c +++ b/examples/cookie.c @@ -22,7 +22,8 @@ void response(magi_request *r) magi_response_init(&head); /* Setting defaults. */ /* Set cookie "cookie" with value "monster" on clientside: */ magi_response_cookie(&head, "cookie", "monster"); - magi_response_free(&head); /* Send headers and start sending body: */ + magi_response_send(&head); /* Send headers, */ + magi_response_free(&head); /* free them and start sending body: */ printf("<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' " "'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>" "<html xmlns='http://www.w3.org/1999/xhtml'>" |