summaryrefslogtreecommitdiff
path: root/apps/netutils/webserver/httpd.h
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-08-31 23:05:51 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-08-31 23:05:51 +0000
commitb351b752486c1693392faed106a8a77609006656 (patch)
tree8b04048671d38afda5fd5fbcea2ae16a9da8bcbc /apps/netutils/webserver/httpd.h
parentf8d292453df82fde56d2e4674ba78b5885fed899 (diff)
downloadnuttx-b351b752486c1693392faed106a8a77609006656.tar.gz
nuttx-b351b752486c1693392faed106a8a77609006656.tar.bz2
nuttx-b351b752486c1693392faed106a8a77609006656.zip
The content for uIP web server demo is no longer canned, but is not built dynameically (Thanks to Max Holtzberg)
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5073 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/netutils/webserver/httpd.h')
-rw-r--r--apps/netutils/webserver/httpd.h58
1 files changed, 2 insertions, 56 deletions
diff --git a/apps/netutils/webserver/httpd.h b/apps/netutils/webserver/httpd.h
index 88e326f70..346159fb2 100644
--- a/apps/netutils/webserver/httpd.h
+++ b/apps/netutils/webserver/httpd.h
@@ -1,8 +1,8 @@
/****************************************************************************
* netutils/webserver/httpd.h
*
- * Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
- * Author: Gregory Nutt <spudmonkey@racsa.co.cr>
+ * Copyright (C) 2007, 2009, 2012 Gregory Nutt. All rights reserved.
+ * Author: Gregory Nutt <gnutt@nuttx.org>
*
* Based on uIP which also has a BSD style license:
*
@@ -46,70 +46,16 @@
#include <nuttx/config.h>
#include <stdint.h>
-#include <nuttx/net/uip/uip.h>
#include <nuttx/net/uip/uipopt.h>
/****************************************************************************
- * Pre-processor Definitions
- ****************************************************************************/
-
-/* As threads are created to handle each request, a stack must be allocated
- * for the thread. Use a default if the user provided no stacksize.
- */
-
-#ifndef CONFIG_NETUTILS_HTTPDSTACKSIZE
-# define CONFIG_NETUTILS_HTTPDSTACKSIZE 4096
-#endif
-
-#undef CONFIG_NETUTILS_HTTPDFSSTATS
-#define CONFIG_NETUTILS_HTTPDFSSTATS 1
-
-#ifndef CONFIG_NET_STATISTICS
-# undef CONFIG_NETUTILS_HTTPDNETSTATS
-#endif
-
-/* For efficiency reasons, the size of the IO buffer should be a multiple
- * of the TCP MSS value. Also, the current design requires that the IO
- * buffer be sufficiently large to contain the entire GET request.
- */
-
-#define HTTPD_IOBUFFER_SIZE (3*UIP_TCP_MSS)
-
-/* this is the maximum size of a file path */
-
-#define HTTPD_MAX_FILENAME 20
-
-/****************************************************************************
* Public Types
****************************************************************************/
-struct httpd_fs_file
-{
- char *data;
- int len;
-};
-
-struct httpd_state
-{
- char ht_buffer[HTTPD_IOBUFFER_SIZE]; /* recv()/send() buffer */
- char ht_filename[HTTPD_MAX_FILENAME]; /* filename from GET command */
- struct httpd_fs_file ht_file; /* Fake file data to send */
- int ht_sockfd; /* The socket descriptor from accept() */
- char *ht_scriptptr;
- uint16_t ht_scriptlen;
- uint16_t ht_sndlen;
-};
-
/****************************************************************************
* Public Function Prototypes
****************************************************************************/
-#ifdef CONFIG_NETUTILS_HTTPDFSSTATS
-#if CONFIG_NETUTILS_HTTPDFSSTATS == 1
-extern uint16_t httpd_fs_count(char *name);
-#endif /* CONFIG_NETUTILS_HTTPDFSSTATS */
-#endif /* CONFIG_NETUTILS_HTTPDFSSTATS */
-
/* file must be allocated by caller and will be filled in by the function. */
int httpd_fs_open(const char *name, struct httpd_fs_file *file);