aboutsummaryrefslogtreecommitdiff
path: root/www/tidy-devel/files/patch-af
blob: 4c9587322849d068ff150e4f3a5c71ec82c9964c (plain) (blame)
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
34
35
36
37
--- localize.c.orig	Fri Aug  4 19:21:05 2000
+++ localize.c	Mon Nov 19 14:39:38 2001
@@ -8,6 +8,9 @@
   to localize HTML tidy.
 */
 
+#include <sys/types.h>
+#include <sys/stat.h>
+
 #include "platform.h"
 #include "html.h"
 
@@ -50,6 +53,16 @@
     tidy_out(fp, "Can't open \"%s\"\n", file);
 }
 
+int FileExists(const char *file)
+{
+    struct stat st;
+
+    if (stat(file, &st) < 0)
+        return (0);
+    else
+        return (1);
+}
+
 static void ReportTag(Lexer *lexer, Node *tag)
 {
     if (tag)
@@ -736,6 +749,7 @@
     tidy_out(out, "  -xml            use this when input is wellformed xml\n");
     tidy_out(out, "  -asxml          to convert html to wellformed xml\n");
     tidy_out(out, "  -slides         to burst into slides on h2 elements\n");
+    tidy_out(out, "  -preserve       to preserve entities from source file\n");
     tidy_out(out, "\n");
 
     tidy_out(out, "Character encodings\n");