libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit b3a45b40e034a077f2a31b141223580218ee4fdd
parent d686cb083345e50e5ce1f5de14fad756fe827a59
Author: Christian Grothoff <christian@grothoff.org>
Date:   Sun, 26 Feb 2017 22:46:24 +0100

apply copyright header

Diffstat:
Msrc/examples/timeout.c | 26++++++++++++++++++++++++++
1 file changed, 26 insertions(+), 0 deletions(-)

diff --git a/src/examples/timeout.c b/src/examples/timeout.c @@ -1,3 +1,28 @@ +/* + This file is part of libmicrohttpd + Copyright (C) 2016, 2017 Christian Grothoff, + Silvio Clecio (silvioprog), Karlson2k (Evgeny Grin) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ +/** + * @file timeout.c + * @brief example for how to use libmicrohttpd request timeout + * @author Christian Grothoff, Silvio Clecio (silvioprog), Karlson2k (Evgeny Grin) + */ + #include <microhttpd.h> #include <stdio.h> #include <string.h> @@ -42,6 +67,7 @@ main (int argc, PORT, NULL, NULL, &answer_to_connection, NULL, + /* 3 seconds */ MHD_OPTION_CONNECTION_TIMEOUT, (unsigned int) 3, MHD_OPTION_END); if (NULL == daemon)