blob: 3796b7cd2947f921e71878d84d58d7df2f54bf49 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
$NetBSD: patch-au,v 1.1 2008/03/18 21:53:41 tonnerre Exp $
--- cgi/cgiutils.c.orig 2006-05-20 20:37:29.000000000 +0200
+++ cgi/cgiutils.c
@@ -1393,6 +1393,28 @@ char * html_encode(char *input){
}
+ /* strip > and < from string */
+ void strip_html_brackets(char *buffer){
+ register int x;
+ register int y;
+ register int z;
+
+ if(buffer==NULL || buffer[0]=='\x0')
+ return;
+
+ /* remove all occurances in string */
+ z=(int)strlen(buffer);
+ for(x=0,y=0;x<z;x++){
+ if(buffer[x]=='<' || buffer[x]=='>')
+ continue;
+ buffer[y++]=buffer[x];
+ }
+ buffer[y++]='\x0';
+
+ return;
+ }
+
+
/* determines the log file we should use (from current time) */
void get_log_archive_to_use(int archive,char *buffer,int buffer_length){
|