Made CFS web server pathname length configurable via WEBSERVER_CONF_CFS_PATHLEN and increased default pathname length from 20 to 80 chars in order to allow to actually make use of subdirs.

This commit is contained in:
oliverschmidt 2010-04-11 20:10:12 +00:00
parent eae42d02d5
commit f22b0dffb3

View file

@ -28,7 +28,7 @@
*
* This file is part of the uIP TCP/IP stack.
*
* $Id: httpd-cfs.h,v 1.2 2007/04/23 23:08:44 oliverschmidt Exp $
* $Id: httpd-cfs.h,v 1.3 2010/04/11 20:10:12 oliverschmidt Exp $
*
*/
@ -37,13 +37,19 @@
#include "contiki-net.h"
#ifndef WEBSERVER_CONF_CFS_PATHLEN
#define HTTPD_PATHLEN 80
#else /* WEBSERVER_CONF_CFS_CONNS */
#define HTTPD_PATHLEN WEBSERVER_CONF_CFS_PATHLEN
#endif /* WEBSERVER_CONF_CFS_CONNS */
struct httpd_state {
struct timer timer;
struct psock sin, sout;
struct pt outputpt;
char inputbuf[50];
char inputbuf[HTTPD_PATHLEN + 30];
char outputbuf[UIP_TCP_MSS];
char filename[20];
char filename[HTTPD_PATHLEN];
char state;
int fd;
int len;