summaryrefslogtreecommitdiffstats
path: root/gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h
diff options
context:
space:
mode:
authoravsm <avsm@openbsd.org>2011-07-22 14:10:37 +0000
committeravsm <avsm@openbsd.org>2011-07-22 14:10:37 +0000
commiteba9f5f4814947c303fbe260c20a9bee9ae7f5e0 (patch)
treefcdbb8178d7ecc9417d44956b2792e940fca0a31 /gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h
parentfix typos, martin pelikan (diff)
downloadwireguard-openbsd-eba9f5f4814947c303fbe260c20a9bee9ae7f5e0.tar.xz
wireguard-openbsd-eba9f5f4814947c303fbe260c20a9bee9ae7f5e0.zip
update to lynx2.8.7rel.2, with local patches:
- restore local lynx.cfg settings [avsm] - fix makefile races [espie] - read/write result checking fixes to avoid unsigned comparisons vs -1 [krw] - initialize all the InputFieldData members correctly [fgsch] - fix socklen_t test to include <sys/types.h> [miod] - fgets(3) returns NULL on error, not 0. No functional change [cloder] ok krw@, tests by Simon Kuhnle and Martin Pieuchot
Diffstat (limited to 'gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h')
-rw-r--r--gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h61
1 files changed, 30 insertions, 31 deletions
diff --git a/gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h b/gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h
index dc3e08f8b2c..09dfdbc4200 100644
--- a/gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h
+++ b/gnu/usr.bin/lynx/WWW/Library/Implementation/HTString.h
@@ -1,8 +1,9 @@
-/* String handling for libwww
- STRINGS
-
- Case-independent string comparison and allocations with copies etc
-
+/*
+ * $LynxId: HTString.h,v 1.31 2009/03/17 22:25:50 tom Exp $
+ * String handling for libwww
+ * STRINGS
+ *
+ * Case-independent string comparison and allocations with copies etc
*/
#ifndef HTSTRING_H
#define HTSTRING_H
@@ -17,8 +18,8 @@ extern "C" {
extern const char *HTLibraryVersion; /* String for help screen etc */
/*
- EBCDIC string comparison using ASCII collating sequence
-*/
+ * EBCDIC string comparison using ASCII collating sequence
+ */
#ifdef NOT_ASCII
extern int AS_casecomp(const char *a, const char *b);
extern int AS_ncmp(const char *a, const char *b, unsigned int n);
@@ -32,13 +33,11 @@ extern "C" {
#endif /* NOT_ASCII */
-/*
-
-Case-insensitive string comparison
-
- The usual routines (comp instead of cmp) had some problem.
-
- */
+ /*
+ * Case-insensitive string comparison
+ *
+ * The usual routines (comp instead of cmp) had some problem.
+ */
extern int strcasecomp(const char *a, const char *b);
extern int strncasecomp(const char *a, const char *b, int n);
@@ -53,33 +52,29 @@ Case-insensitive string comparison
* current display charset
*/
-/*
-
-Malloced string manipulation
-
- */
+ /*
+ * Malloced string manipulation
+ */
#define StrAllocCopy(dest, src) HTSACopy (&(dest), src)
#define StrAllocCat(dest, src) HTSACat (&(dest), src)
extern char *HTSACopy(char **dest, const char *src);
extern char *HTSACat(char **dest, const char *src);
-/*
-optimized for heavily realloc'd strings in temp objects
-*/
+ /*
+ * optimized for heavily realloc'd strings in temp objects
+ */
#define StrAllocCopy_extra(dest, src) HTSACopy_extra (&(dest), src)
#define FREE_extra(x) {if (x != NULL) {HTSAFree_extra(x); x = NULL;}}
#define Clear_extra(x) {if (x != NULL) {*x = '\0';}}
extern char *HTSACopy_extra(char **dest, const char *src);
extern void HTSAFree_extra(char *s);
-/*
-
-Next word or quoted string
-
- */
+ /*
+ * Next word or quoted string
+ */
extern char *HTNextField(char **pstr);
-/* A more general parser - kw */
+ /* A more general parser - kw */
extern char *HTNextTok(char **pstr,
const char *delims, const char *bracks, char *found);
@@ -93,10 +88,14 @@ Next word or quoted string
va_list * ap);
#endif
-#if (defined(VMS) || defined(DOSPATH) || defined(__EMX__)) && !defined(__CYGWIN__)
-#define USE_QUOTED_PARAMETER 0
+#if defined(__CYGWIN__)
+#define USE_QUOTED_PARAMETER 2 /* single and double-quoting */
+#elif defined(DOSPATH)
+#define USE_QUOTED_PARAMETER 1 /* double-quoting only */
+#elif (defined(VMS) || defined(__EMX__))
+#define USE_QUOTED_PARAMETER 0 /* no quoting */
#else
-#define USE_QUOTED_PARAMETER 1
+#define USE_QUOTED_PARAMETER 2 /* single and double-quoting */
#endif
#if USE_QUOTED_PARAMETER