patch-2.3.15 linux/net/khttpd/rfc.c
Next file: linux/net/khttpd/security.c
Previous file: linux/net/khttpd/misc.c
Back to the patch index
Back to the overall index
- Lines: 26
- Date:
Mon Aug 23 10:41:25 1999
- Orig file:
v2.3.14/linux/net/khttpd/rfc.c
- Orig date:
Wed Aug 18 09:50:16 1999
diff -u --recursive --new-file v2.3.14/linux/net/khttpd/rfc.c linux/net/khttpd/rfc.c
@@ -43,7 +43,6 @@
#include <asm/semaphore.h>
#include <asm/processor.h>
#include <asm/uaccess.h>
-#include <asm/msr.h>
#include "prototypes.h"
@@ -90,7 +89,7 @@
MimeTypes[atomic_read(&MimeCount)].identifier=*I;
- strcpy(MimeTypes[atomic_read(&MimeCount)].type,Type);
+ strncpy(MimeTypes[atomic_read(&MimeCount)].type,Type,(64-sizeof(__u32)-sizeof(__kernel_size_t)));
MimeTypes[atomic_read(&MimeCount)].len = strlen(Type);
atomic_inc(&MimeCount);
@@ -325,7 +324,7 @@
if (tmp>Endval) continue;
- strcpy(Head->FileName,sysctl_khttpd_docroot);
+ strncpy(Head->FileName,sysctl_khttpd_docroot,sizeof(Head->FileName));
PrefixLen = strlen(sysctl_khttpd_docroot);
Head->FileNameLength = min(255,tmp-Buffer+PrefixLen);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)