浏览代码

* PChar -> PAnsichar

Michaël Van Canneyt 2 年之前
父节点
当前提交
239224f99e

+ 17 - 17
packages/httpd13/src/ap.inc

@@ -20,18 +20,18 @@
  * Tsirigotis <[email protected]> for xinetd.
  }
 
-function ap_cpystrn(param1: PChar; const param2: PChar; param3: size_t): PChar;
+function ap_cpystrn(param1: PAnsiChar; const param2: PAnsiChar; param3: size_t): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 {int ap_slack(int, int);
-int ap_execle(const char *, const char *, ...);
-int ap_execve(const char *, char * const argv[], char * const envp[]); }
+int ap_execle(const AnsiChar *, const AnsiChar *, ...);
+int ap_execve(const AnsiChar *, AnsiChar * const argv[], AnsiChar * const envp[]); }
 
-//function ap_getpass(const prompt: PChar; pwbuf: PChar; bufsiz: size_t): cint;
+//function ap_getpass(const prompt: PAnsiChar; pwbuf: PAnsiChar; bufsiz: size_t): cint;
 // {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 //{$ifndef ap_strtol}
-//function ap_strtol(const nptr: PChar; endptr: PPChar; base: cint): clong;
+//function ap_strtol(const nptr: PAnsiChar; endptr: PPAnsiChar; base: cint): clong;
 // {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 //{$endif}
 
@@ -98,8 +98,8 @@ int ap_execve(const char *, char * const argv[], char * const envp[]); }
 
 type
   ap_vformatter_buff = record
-    curpos: PChar;
-    endpos: PChar;
+    curpos: PAnsiChar;
+    endpos: PAnsiChar;
   end;
   
   Pap_vformatter_buff = ^ap_vformatter_buff;
@@ -107,7 +107,7 @@ type
   flush_func_t = function (param: Pap_vformatter_buff): cint;
 
 function ap_vformatter(flush_func: flush_func_t;
- param2: Pap_vformatter_buff; const fmt: PChar; ap: va_list): cint;
+ param2: Pap_vformatter_buff; const fmt: PAnsiChar; ap: va_list): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { These are snprintf implementations based on ap_vformatter().
@@ -127,12 +127,12 @@ function ap_vformatter(flush_func: flush_func_t;
  *
  * In no event does ap_snprintf return a negative number.
  }
-function ap_snprintf(buf: PChar; len: size_t; const format: PChar;
+function ap_snprintf(buf: PAnsiChar; len: size_t; const format: PAnsiChar;
  others: array of const): cint; cdecl; external LibHTTPD;
 
 //			    __attribute__((format(printf,3,4)));
 
-function ap_vsnprintf(buf: PChar; len: size_t; const format: PChar; ap: va_list): cint;
+function ap_vsnprintf(buf: PAnsiChar; len: size_t; const format: PAnsiChar; ap: va_list): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { Simple BASE64 encode/decode functions.
@@ -140,7 +140,7 @@ function ap_vsnprintf(buf: PChar; len: size_t; const format: PChar; ap: va_list)
  * As we might encode binary strings, hence we require the length of
  * the incoming plain source. And return the length of what we decoded.
  *
- * The decoding function takes any non valid char (i.e. whitespace, \0
+ * The decoding function takes any non valid AnsiChar (i.e. whitespace, \0
  * or anything non A-Z,0-9 etc as terminal.
  * 
  * plain strings/binary sequences are not assumed '\0' terminated. Encoded
@@ -150,26 +150,26 @@ function ap_vsnprintf(buf: PChar; len: size_t; const format: PChar; ap: va_list)
 function ap_base64encode_len(len: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_base64encode(coded_dst: PChar; const plain_src: PChar; len_plain_src: cint): cint;
+function ap_base64encode(coded_dst: PAnsiChar; const plain_src: PAnsiChar; len_plain_src: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_base64encode_binary(coded_dst: PChar; const plain_src: PChar; len_plain_src: cint): cint;
+function ap_base64encode_binary(coded_dst: PAnsiChar; const plain_src: PAnsiChar; len_plain_src: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 
-function ap_base64decode_len(const coded_src: PChar): cint;
+function ap_base64decode_len(const coded_src: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_base64decode(plain_dst: PChar; const coded_src: PChar): cint;
+function ap_base64decode(plain_dst: PAnsiChar; const coded_src: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_base64decode_binary(plain_dst: PChar; const coded_src: PChar): cint;
+function ap_base64decode_binary(plain_dst: PAnsiChar; const coded_src: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { Password validation, as used in AuthType Basic which is able to cope
  * (based on the prefix) with the SHA1, Apache's internal MD5 and (depending
  * on your platform either plain or crypt(3) passwords.
  }
-function ap_validate_password(const passwd, hash: PChar): PChar;
+function ap_validate_password(const passwd, hash: PAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 

+ 24 - 24
packages/httpd13/src/ap_alloc.inc

@@ -123,18 +123,18 @@ function ap_palloc(p: PPool; nbytes: cint): Pointer;
 function ap_pcalloc(p: PPool; nbytes: cint): Pointer;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_pstrdup(p: PPool; const s: Char): PChar;
+function ap_pstrdup(p: PPool; const s: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { make a nul terminated copy of the n characters starting with s }
 
-function ap_pstrndup(p: PPool; const s: PChar; n: cint): PChar;
+function ap_pstrndup(p: PPool; const s: PAnsiChar; n: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-//API_EXPORT_NONSTD(char *) ap_pstrcat(struct pool *,...);	{ all '...' must be char* }
-//API_EXPORT_NONSTD(char *) ap_psprintf(struct pool *, const char *fmt, ...)
+//API_EXPORT_NONSTD(AnsiChar *) ap_pstrcat(struct pool *,...);	{ all '...' must be AnsiChar* }
+//API_EXPORT_NONSTD(AnsiChar *) ap_psprintf(struct pool *, const AnsiChar *fmt, ...)
 //    __attribute__((format(printf,2,3)));
-//API_EXPORT(char *) ap_pvsprintf(struct pool *, const char *fmt, va_list);
+//API_EXPORT(AnsiChar *) ap_pvsprintf(struct pool *, const AnsiChar *fmt, va_list);
 
 { array and alist management... keeping lists of things.
  * Common enough to want common support code ...
@@ -148,7 +148,7 @@ type
     elt_size: cint;
     nelts: cint;
     nalloc: cint;
-    elts: PChar;
+    elts: PAnsiChar;
   end;
 
 //API_EXPORT(array_header *) ap_make_array(pool *p, int nelts, int elt_size);
@@ -163,7 +163,7 @@ type
  * or if there are no elements in the array.
  * If sep is non-NUL, it will be inserted between elements as a separator.
  }
-function ap_array_pstrcat(p: PPool; const arr: Parray_header; const sep: Char): PChar;
+function ap_array_pstrcat(p: PPool; const arr: Parray_header; const sep: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { copy_array copies the *entire* array.  copy_array_hdr just copies
@@ -190,10 +190,10 @@ type
   Ptable = ^table;
 
   table_entry = record
-    key: PChar;		{ maybe NULL in future;
+    key: PAnsiChar;		{ maybe NULL in future;
 			 * check when iterating thru table_elts
                          }
-    val: PChar;
+    val: PAnsiChar;
   end;
 
   table_entry_t = table_entry;
@@ -207,31 +207,31 @@ function ap_copy_table(p: Ppool; p1: Ptable): Ptable;
 procedure ap_clear_table(p1: Ptable);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_table_get(const p1: Ptable; const p2: PChar): PChar;
+function ap_table_get(const p1: Ptable; const p2: PAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_set(p1: Ptable; const name, val: PChar);
+procedure ap_table_set(p1: Ptable; const name, val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_setn(p1: Ptable; const name, val: PChar);
+procedure ap_table_setn(p1: Ptable; const name, val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_merge(p1: Ptable; const name, more_val: PChar);
+procedure ap_table_merge(p1: Ptable; const name, more_val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_mergen(p1: Ptable; const name, more_val: PChar);
+procedure ap_table_mergen(p1: Ptable; const name, more_val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_unset(p1: Ptable; const key: PChar);
+procedure ap_table_unset(p1: Ptable; const key: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_add(p1: Ptable; const name, more_val: PChar);
+procedure ap_table_add(p1: Ptable; const name, more_val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_table_addn(p1: Ptable; const name, more_val: PChar);
+procedure ap_table_addn(p1: Ptable; const name, more_val: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-{API_EXPORT_NONSTD(void) ap_table_do(int ( *comp) (void *, const char *, const char *),
+{API_EXPORT_NONSTD(void) ap_table_do(int ( *comp) (void *, const AnsiChar *, const AnsiChar *),
                                     void *rec, const table *t,...);
 
 API_EXPORT(table * ) ap_overlay_tables(pool *p, const table *overlay, const table *base);
@@ -334,13 +334,13 @@ procedure ap_unblock_alarms;
  * the note_cleanups_for_foo routines are for 
  }
 
-{API_EXPORT(FILE *) ap_pfopen(struct pool *, const char *name, const char *fmode);
-API_EXPORT(FILE *) ap_pfdopen(struct pool *, int fd, const char *fmode);}
+{API_EXPORT(FILE *) ap_pfopen(struct pool *, const AnsiChar *name, const AnsiChar *fmode);
+API_EXPORT(FILE *) ap_pfdopen(struct pool *, int fd, const AnsiChar *fmode);}
 
-function ap_popenf(p1: Ppool; const name: PChar; flg, mode: cint): cint;
+function ap_popenf(p1: Ppool; const name: PAnsiChar; flg, mode: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_popenf_ex(p1: Ppool; const name: PChar; flg, mode, domagic: cint): cint;
+function ap_popenf_ex(p1: Ppool; const name: PAnsiChar; flg, mode, domagic: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 {API_EXPORT(void) ap_note_cleanups_for_file(pool *, FILE *);
@@ -379,7 +379,7 @@ function ap_pclosesocket(a: Ppool; sock: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 
-function ap_pregcomp(p: Ppool; const pattern: PChar; cflags: cint): Pregex_t;
+function ap_pregcomp(p: Ppool; const pattern: PAnsiChar; cflags: cint): Pregex_t;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 procedure ap_pregfree(p: Ppool; reg: Pregex_t);
@@ -400,7 +400,7 @@ function ap_pclosef(p1: Ppool; fd: cint): cint;
 
 { routines to deal with directories }
 
-function ap_popendir(p: Ppool; const name: PChar): PDIR;
+function ap_popendir(p: Ppool; const name: PAnsiChar): PDIR;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 procedure ap_pclosedir(p: Ppool; d: PDIR);

+ 49 - 49
packages/httpd13/src/ap_config.inc

@@ -74,9 +74,9 @@ type rlim_t = cint;
 {$define HAVE_FLOCK_SERIALIZED_ACCEPT}
 {$define _BSD_SOURCE}
 #define EAGAIN EWOULDBLOCK
-int initgroups (char *, int);     
-char *crypt (const char *pw, const char *salt);
-int gethostname (char *name, int namelen);
+int initgroups (AnsiChar *, int);     
+AnsiChar *crypt (const AnsiChar *pw, const AnsiChar *salt);
+int gethostname (AnsiChar *name, int namelen);
 
 {$else}{$if defined(MPE)}
 #include <sys/times.h>
@@ -102,7 +102,7 @@ const
   {$define NEED_STRNCASECMP}
 //extern void GETPRIVMODE();
 //extern void GETUSERMODE();
-//extern char *inet_ntoa();
+//extern AnsiChar *inet_ntoa();
   {$define NO_SLACK}
   S_IEXEC  = S_IXUSR;
   S_IREAD  = S_IRUSR;
@@ -115,8 +115,8 @@ const
   HAVE_GMTOFF = 1;
 {$undefine NO_KILLPG}
 #undef NO_SETSID
-//char *crypt(const char *pw, const char *salt);
-//char *mktemp(char *);
+//AnsiChar *crypt(const AnsiChar *pw, const AnsiChar *salt);
+//AnsiChar *mktemp(AnsiChar *);
   HAVE_MMAP = 1;
 {$define USE_MMAP_SCOREBOARD}
 {$define USE_MMAP_FILES}
@@ -145,7 +145,7 @@ type rlim_t = cint;
 #define HAVE_MMAP 1
 #define USE_MMAP_SCOREBOARD
 #define USE_MMAP_FILES
-int gethostname(char *name, int namelen);
+int gethostname(AnsiChar *name, int namelen);
 #define HAVE_SYSLOG 1
 #define SYS_SIGLIST _sys_siglist
 #define AP_ENABLE_EXCEPTION_HOOK
@@ -523,23 +523,23 @@ const
 
 { Although SCO 5 defines these in <strings.h> (note the "s") they don't have
    consts. Sigh. }
-extern int strcasecmp(const char *, const char *);
-extern int strncasecmp(const char *, const char *, unsigned);
+extern int strcasecmp(const AnsiChar *, const AnsiChar *);
+extern int strncasecmp(const AnsiChar *, const AnsiChar *, unsigned);
 
 {$else}{$if defined(AUX3)}
 { These are to let -Wall compile more cleanly }
-extern int strcasecmp(const char *, const char *);
-extern int strncasecmp(const char *, const char *, unsigned);
+extern int strcasecmp(const AnsiChar *, const AnsiChar *);
+extern int strncasecmp(const AnsiChar *, const AnsiChar *, unsigned);
 extern int set42sig(), getopt(), getpeername(), bzero();
 extern int listen(), bind(), socket(), getsockname();
 extern int accept(), gethostname(), connect(), lstat();
 extern int select(), killpg(), shutdown();
 extern int initgroups(), setsockopt();
-extern char *shmat();
+extern AnsiChar *shmat();
 extern int shmctl();
 extern int shmget();
-extern char *sbrk();
-extern char *crypt();
+extern AnsiChar *sbrk();
+extern AnsiChar *crypt();
 #include <sys/time.h>
 #undef HAVE_GMTOFF
 #undef NO_KILLPG
@@ -724,10 +724,10 @@ typedef quad_t rlim_t;
 
 {$else}{$if defined(QNX)}
 #ifndef crypt
-char *crypt(const char *pw, const char *salt);
+AnsiChar *crypt(const AnsiChar *pw, const AnsiChar *salt);
 #endif
 #ifndef initgroups
-int initgroups(char *, int);
+int initgroups(AnsiChar *, int);
 #endif
 #ifndef strncasecmp
 #define strncasecmp strnicmp
@@ -756,7 +756,7 @@ int initgroups(char *, int);
 #undef NO_SETSID
 #undef NO_USE_SIGACTION
 #undef NO_LINGCLOSE
-extern char *crypt(char *pw, char *salt);
+extern AnsiChar *crypt(AnsiChar *pw, AnsiChar *salt);
 typedef int rlim_t;
 #define HAVE_SYSLOG 1
 
@@ -1331,7 +1331,7 @@ Sigfunc *signal(int signo, Sigfunc * func);
 #endif
 
 #ifdef ULTRIX_BRAIN_DEATH
-#define ap_fdopen(d,m) fdopen((d), (char *)(m))
+#define ap_fdopen(d,m) fdopen((d), (AnsiChar *)(m))
 #else
 #define ap_fdopen(d,m) fdopen((d), (m))
 #endif
@@ -1348,9 +1348,9 @@ Sigfunc *signal(int signo, Sigfunc * func);
  * with a HASHBANG (#!) followed by interpreter name and args, define this.
  }
 {#ifdef NEED_HASHBANG_EMUL
-extern int ap_execle(const char *filename, const char *arg,...);
-extern int ap_execve(const char *filename, char * const argv[],
-                     char * const envp[]);}
+extern int ap_execle(const AnsiChar *filename, const AnsiChar *arg,...);
+extern int ap_execve(const AnsiChar *filename, AnsiChar * const argv[],
+                     AnsiChar * const envp[]);}
 { ap_execle() is a wrapper function around ap_execve(). }
 {#define execle  ap_execle
 #define execve(path,argv,envp)  ap_execve(path,argv,envp)
@@ -1378,7 +1378,7 @@ extern int ap_execve(const char *filename, char * const argv[],
 //#else { ! (CRAY || __arm) }
 
 //#define XtOffset(p_type,field) \
-//	((long) (((char *) (&(((p_type)NULL)->field))) - ((char *) NULL)))
+//	((long) (((AnsiChar *) (&(((p_type)NULL)->field))) - ((AnsiChar *) NULL)))
 
 //#endif { !CRAY }
 
@@ -1427,42 +1427,42 @@ type NET_SIZE_T = cint;
  * currently (13Nov97) used.
  }
 
-{int getopt(int, char **, char *);
+{int getopt(int, AnsiChar **, AnsiChar *);
 
-int strcasecmp(const char *, const char *);
-int strncasecmp(const char *, const char *, int);
+int strcasecmp(const AnsiChar *, const AnsiChar *);
+int strncasecmp(const AnsiChar *, const AnsiChar *, int);
 int toupper(int);
 int tolower(int);
 
-int printf(char *,...);
-int fprintf(FILE *, char *,...);
-int fputs(char *, FILE *);
-int fread(char *, int, int, FILE *);
-int fwrite(char *, int, int, FILE *);
+int printf(AnsiChar *,...);
+int fprintf(FILE *, AnsiChar *,...);
+int fputs(AnsiChar *, FILE *);
+int fread(AnsiChar *, int, int, FILE *);
+int fwrite(AnsiChar *, int, int, FILE *);
 int fgetc(FILE *);
-char *fgets(char *s, int, FILE*);
+AnsiChar *fgets(AnsiChar *s, int, FILE*);
 int fflush(FILE *);
 int fclose(FILE *);
 int ungetc(int, FILE *);
 int _filbuf(FILE *);	}{ !!! }
-//int _flsbuf(unsigned char, FILE *);	{ !!! }
-{int sscanf(char *, char *,...);
-void setbuf(FILE *, char *);
-void perror(char *);
+//int _flsbuf(unsigned AnsiChar, FILE *);	{ !!! }
+{int sscanf(AnsiChar *, AnsiChar *,...);
+void setbuf(FILE *, AnsiChar *);
+void perror(AnsiChar *);
 
 time_t time(time_t *);
-int strftime(char *, int, const char *, struct tm *);
+int strftime(AnsiChar *, int, const AnsiChar *, struct tm *);
 
-int initgroups(char *, int);}
+int initgroups(AnsiChar *, int);}
 //int wait3(int *, int, void *);	{ Close enough for us... }
-{int lstat(const char *, struct stat *);
-int stat(const char *, struct stat *);
+{int lstat(const AnsiChar *, struct stat *);
+int stat(const AnsiChar *, struct stat *);
 int flock(int, int);
 #ifndef NO_KILLPG
 int killpg(int, int);
 #endif
 int socket(int, int, int);
-int setsockopt(int, int, int, const char *, int);
+int setsockopt(int, int, int, const AnsiChar *, int);
 int listen(int, int);
 int bind(int, struct sockaddr *, int);
 int connect(int, struct sockaddr *, int);
@@ -1471,11 +1471,11 @@ int shutdown(int, int);
 
 int getsockname(int s, struct sockaddr *name, int *namelen);
 int getpeername(int s, struct sockaddr *name, int *namelen);
-int gethostname(char *name, int namelen);
-void syslog(int, char *,...);
-char *mktemp(char *);
+int gethostname(AnsiChar *name, int namelen);
+void syslog(int, AnsiChar *,...);
+AnsiChar *mktemp(AnsiChar *);
 
-int vfprintf(FILE *, const char *, va_list);
+int vfprintf(FILE *, const AnsiChar *, va_list);
 
 #endif} { SUNOS_LIB_PROTOTYPES }
 
@@ -1484,22 +1484,22 @@ int vfprintf(FILE *, const char *, va_list);
  * Declare what is needed exactly as the replacement routines implement it.
  }
 {#ifdef NEED_STRDUP
-extern char *strdup (const char *str);
+extern AnsiChar *strdup (const AnsiChar *str);
 #endif
 #ifdef NEED_STRCASECMP
-extern int strcasecmp (const char *a, const char *b);
+extern int strcasecmp (const AnsiChar *a, const AnsiChar *b);
 #endif
 #ifdef NEED_STRNCASECMP
-extern int strncasecmp (const char *a, const char *b, int n);
+extern int strncasecmp (const AnsiChar *a, const AnsiChar *b, int n);
 #endif
 #ifdef NEED_INITGROUPS
-extern int initgroups(const char *name, gid_t basegid);
+extern int initgroups(const AnsiChar *name, gid_t basegid);
 #endif
 #ifdef NEED_WAITPID
 extern int waitpid(pid_t pid, int *statusp, int options);
 #endif
 #ifdef NEED_STRERROR
-extern char *strerror (int err);
+extern AnsiChar *strerror (int err);
 #endif
 #ifdef NEED_DIFFTIME
 extern double difftime(time_t time1, time_t time0);

+ 14 - 14
packages/httpd13/src/buff.inc

@@ -62,16 +62,16 @@ type
 
   buff_struct = record
     flags: cint;		{ flags }
-    inptr: PChar;      	        { pointer to next location to read }
+    inptr: PAnsiChar;      	        { pointer to next location to read }
     incnt: cint;		{ number of bytes left to read from input buffer;
 				 * always 0 if had a read error  }
     outchunk: cint;		{ location of chunk header when chunking }
     outcnt: cint;		{ number of byte put in output buffer }
-    inbase: PChar;
-    outbase: PChar;
+    inbase: PAnsiChar;
+    outbase: PAnsiChar;
     bufsiz: cint;
     error: error_t;
-    error_data: PChar;
+    error_data: PAnsiChar;
     bytes_sent: clong;  	{ number of bytes actually written }
 
     pool: Pap_pool;
@@ -84,7 +84,7 @@ type
 {$endif}
 
     { transport handle, for RPC binding handle or some such }
-    t_handle: PChar;
+    t_handle: PAnsiChar;
 
 {$ifdef B_SFIO}
     sf_in: PSfio_t;
@@ -146,16 +146,16 @@ procedure ap_bonerror(fb: PBUFF; error: error_t; data: Pointer);
 { I/O }
 function ap_bread(fb: PBUFF; buf: Pointer; nbyte: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
-{API_EXPORT(int) ap_bgets(char *s, int n, BUFF *fb);
-API_EXPORT(int) ap_blookc(char *buff, BUFF *fb);
+{API_EXPORT(int) ap_bgets(AnsiChar *s, int n, BUFF *fb);
+API_EXPORT(int) ap_blookc(AnsiChar *buff, BUFF *fb);
 API_EXPORT(int) ap_bskiplf(BUFF *fb);
 API_EXPORT(int) ap_bwrite(BUFF *fb, const void *buf, int nbyte);
 API_EXPORT(int) ap_bflush(BUFF *fb);
-API_EXPORT(int) ap_bputs(const char *x, BUFF *fb);
+API_EXPORT(int) ap_bputs(const AnsiChar *x, BUFF *fb);
 API_EXPORT_NONSTD(int) ap_bvputs(BUFF *fb,...);
-API_EXPORT_NONSTD(int) ap_bprintf(BUFF *fb, const char *fmt,...)
+API_EXPORT_NONSTD(int) ap_bprintf(BUFF *fb, const AnsiChar *fmt,...)
 				__attribute__((format(printf,2,3)));
-API_EXPORT(int) ap_vbprintf(BUFF *fb, const char *fmt, va_list vlist);
+API_EXPORT(int) ap_vbprintf(BUFF *fb, const AnsiChar *fmt, va_list vlist);
 }
 { Internal routines }
 {API_EXPORT(int) ap_bflsbuf(int c, BUFF *fb);
@@ -174,12 +174,12 @@ API_EXPORT(int) ap_bfilbuf(BUFF *fb);
 {
 #define ap_bgetc(fb)   ( ((fb)->incnt == 0) ? ap_bfilbuf(fb) : \
 		    ((fb)->incnt--, (fb->flags & B_ASCII2EBCDIC)\
-		    ?os_toebcdic[(unsigned char)*((fb)->inptr++)]:*((fb)->inptr++)) )
+		    ?os_toebcdic[(unsigned AnsiChar)*((fb)->inptr++)]:*((fb)->inptr++)) )
 
 #define ap_bputc(c, fb) ((((fb)->flags & (B_EOUT|B_WRERR|B_WR)) != B_WR || \
 		     (fb)->outcnt == (fb)->bufsiz) ? ap_bflsbuf(c, (fb)) : \
 		     ((fb)->outbase[(fb)->outcnt++] = (fb->flags & B_EBCDIC2ASCII)\
-		     ?os_toascii[(unsigned char)c]:(c), 0))
+		     ?os_toascii[(unsigned AnsiChar)c]:(c), 0))
 
 #endif} {CHARSET_EBCDIC}
 
@@ -227,8 +227,8 @@ procedure ap_bhalfduplex(fb: PBUFF);
 {$if defined(WINDOWS) or defined(NETWARE) or defined(CYGWIN_WINSOCK)}
 
 { ap_recvwithtimeout/ap_sendwithtimeout socket primitives for WinSock }
-//API_EXPORT(int) ap_sendwithtimeout(int sock, const char *buf, int len, int flags);
-//API_EXPORT(int) ap_recvwithtimeout(int sock, char *buf, int len, int flags);
+//API_EXPORT(int) ap_sendwithtimeout(int sock, const AnsiChar *buf, int len, int flags);
+//API_EXPORT(int) ap_recvwithtimeout(int sock, AnsiChar *buf, int len, int flags);
 
 {$endif}
 

+ 4 - 4
packages/httpd13/src/hsregex.inc

@@ -32,7 +32,7 @@ type
   regex_t = record
     re_magic: cint;
     re_nsub: size_t;		{ number of parenthesized subexpressions }
-    re_endp: PChar;     	{ end pointer for REG_PEND }
+    re_endp: PAnsiChar;     	{ end pointer for REG_PEND }
     re_g: Pre_guts;	{ none of your business :-) }
   end;
 
@@ -43,7 +43,7 @@ type
 
 
 { === regcomp.c === }
-//API_EXPORT(int) regcomp(regex_t *, const char *, int);
+//API_EXPORT(int) regcomp(regex_t *, const AnsiChar *, int);
 
 const
  	REG_BASIC	= 0000;
@@ -76,11 +76,11 @@ const
  	REG_ATOI	=255;	{ convert name to number (!) }
  	REG_ITOA	=0400;	{ convert number to name (!) }
 
-//API_EXPORT(size_t) regerror(int, const regex_t *, char *, size_t);
+//API_EXPORT(size_t) regerror(int, const regex_t *, AnsiChar *, size_t);
 
 
 { === regexec.c === }
-//API_EXPORT(int) regexec(const regex_t *, const char *, size_t, regmatch_t [], int);
+//API_EXPORT(int) regexec(const regex_t *, const AnsiChar *, size_t, regmatch_t [], int);
 
 const
  	REG_NOTBOL	= 00001;

+ 25 - 25
packages/httpd13/src/http_config.inc

@@ -45,10 +45,10 @@ type
     TAKE13			{ one or three arguments }
   );
 
-  cs_func_t = function (): PChar;
+  cs_func_t = function (): PAnsiChar;
   
   command_struct = record
-    name: PChar;		{ Name of this command }
+    name: PAnsiChar;		{ Name of this command }
     func: cs_func_t;       	{ Function invoked }
     cmd_data: Pointer;		{ Extra data, for functions which
 				 * implement multiple commands...
@@ -58,7 +58,7 @@ type
                                  }
     args_how: cmd_how;  	{ What the command expects as arguments }
 
-    errmsg: PChar;		{ 'usage' message, in case of syntax errors }
+    errmsg: PAnsiChar;		{ 'usage' message, in case of syntax errors }
   end;
 
   command_rec = command_struct;
@@ -120,7 +120,7 @@ type
 				 * request is served...
                                  }
     server: Pserver_rec;	{ Server_rec being configured for }
-    path: PChar;	        { If configuring for a directory,
+    path: PAnsiChar;	        { If configuring for a directory,
 				 * pathname of that directory.
 				 * NOPE!  That's what it meant previous to the
 				 * existance of <Files>, <Location> and regex
@@ -130,7 +130,7 @@ type
 				 * or being called in a dir context (path != NULL).
                                  }
     cmd: Pcommand_rec;	        { configuration command }
-    end_token: PChar;  	        { end token required to end a nested section }
+    end_token: PAnsiChar;  	        { end token required to end a nested section }
     context: Pointer;		{ per_dir_config vector passed
 				 * to handle_command }
   end;
@@ -142,7 +142,7 @@ type
   Phandler_rec = ^handler_rec;
   
   handler_rec = record
-    content_type: PChar;	{ MUST be all lower case }
+    content_type: PAnsiChar;	{ MUST be all lower case }
     handler: handler_t;
   end;
 
@@ -162,7 +162,7 @@ type
     merge_server_config_t = function (): Pointer; cdecl;
 {$else}
     init_t = procedure (param1: Pserver_rec; param2: Ppool); cdecl;
-    create_dir_config_t = function (p: Ppool; dir: PChar): Pointer; cdecl;
+    create_dir_config_t = function (p: Ppool; dir: PAnsiChar): Pointer; cdecl;
     merge_dir_config_t = function (p: PPool; base_conf, new_conf: Pointer): Pointer; cdecl;
     create_server_config_t = function (p: Ppool; s: Pserver_rec): Pointer; cdecl;
     merge_server_config_t = function (p: Ppool; base_conf, new_conf: Pointer): Pointer; cdecl;
@@ -190,7 +190,7 @@ type
 				 * config vectors.
                                  }
 
-    name: PChar;
+    name: PAnsiChar;
     dynamic_load_handle: Pointer;
 
     next: Pmodule_struct;
@@ -288,17 +288,17 @@ API_EXPORT(void) ap_set_module_config(void *conf_vector, module *m, void *val);
 
 { Generic command handling function... }
 
-{API_EXPORT_NONSTD(const char *) ap_set_string_slot(cmd_parms *, char *, char *);
-API_EXPORT_NONSTD(const char *) ap_set_string_slot_lower(cmd_parms *, char *, char *);
-API_EXPORT_NONSTD(const char *) ap_set_flag_slot(cmd_parms *, char *, int);
-API_EXPORT_NONSTD(const char *) ap_set_file_slot(cmd_parms *, char *, char *);}
+{API_EXPORT_NONSTD(const AnsiChar *) ap_set_string_slot(cmd_parms *, AnsiChar *, AnsiChar *);
+API_EXPORT_NONSTD(const AnsiChar *) ap_set_string_slot_lower(cmd_parms *, AnsiChar *, AnsiChar *);
+API_EXPORT_NONSTD(const AnsiChar *) ap_set_flag_slot(cmd_parms *, AnsiChar *, int);
+API_EXPORT_NONSTD(const AnsiChar *) ap_set_file_slot(cmd_parms *, AnsiChar *, AnsiChar *);}
 
 { For modules which need to read config files, open logs, etc. ...
  * this returns the fname argument if it begins with '/'; otherwise
  * it relativizes it wrt server_root.
  }
 
-//API_EXPORT(char *) ap_server_root_relative(pool *p, char *fname);
+//API_EXPORT(AnsiChar *) ap_server_root_relative(pool *p, AnsiChar *fname);
 
 { Finally, the hook for dynamically loading modules in... }
 
@@ -311,20 +311,20 @@ procedure ap_remove_module(m: Pmodule);
 procedure ap_add_loaded_module(m: Pmodule);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_add_named_module(const name: PChar): cint;
+function ap_add_named_module(const name: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 procedure ap_clear_module_list();
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_find_module_name(m: Pmodule): PChar;
+function ap_find_module_name(m: Pmodule): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_find_linked_module(const name: PChar): Pmodule;
+function ap_find_linked_module(const name: PAnsiChar): Pmodule;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { for implementing subconfigs and customized config files }
-{API_EXPORT(const char *) ap_srm_command_loop(cmd_parms *parms, void *config);
+{API_EXPORT(const AnsiChar *) ap_srm_command_loop(cmd_parms *parms, void *config);
 
 #ifdef CORE_PRIVATE
 
@@ -340,7 +340,7 @@ extern API_VAR_EXPORT module **ap_loaded_modules;}
 
 { For http_main.c... }
 
-{API_EXPORT(server_rec *) ap_read_config(pool *conf_pool, pool *temp_pool, char *config_name);
+{API_EXPORT(server_rec *) ap_read_config(pool *conf_pool, pool *temp_pool, AnsiChar *config_name);
 API_EXPORT(void) ap_init_modules(pool *p, server_rec *s);
 API_EXPORT(void) ap_child_init_modules(pool *p, server_rec *s);
 API_EXPORT(void) ap_child_exit_modules(pool *p, server_rec *s);
@@ -358,14 +358,14 @@ CORE_EXPORT(void *) ap_merge_per_dir_configs(pool *p, void *base, void *new);}
 { For http_core.c... (<Directory> command and virtual hosts) }
 
 {CORE_EXPORT(int) ap_parse_htaccess(void **result, request_rec *r, int override,
-		const char *path, const char *access_name);
+		const AnsiChar *path, const AnsiChar *access_name);
 
-CORE_EXPORT(const char *) ap_init_virtual_host(pool *p, const char *hostname,
+CORE_EXPORT(const AnsiChar *) ap_init_virtual_host(pool *p, const AnsiChar *hostname,
 				server_rec *main_server, server_rec **);
-CORE_EXPORT(void) ap_process_resource_config(server_rec *s, char *fname, pool *p, pool *ptemp);
+CORE_EXPORT(void) ap_process_resource_config(server_rec *s, AnsiChar *fname, pool *p, pool *ptemp);
 }
 { ap_check_cmd_context() definitions: }
-//API_EXPORT(const char *) ap_check_cmd_context(cmd_parms *cmd, unsigned forbidden);
+//API_EXPORT(const AnsiChar *) ap_check_cmd_context(cmd_parms *cmd, unsigned forbidden);
 
 { ap_check_cmd_context():              Forbidden in: }
 const
@@ -393,10 +393,10 @@ const
 
 { for mod_perl }
 
-//CORE_EXPORT(const command_rec *) ap_find_command(const char *name, const command_rec *cmds);
-//CORE_EXPORT(const command_rec *) ap_find_command_in_modules(const char *cmd_name, module **mod);
+//CORE_EXPORT(const command_rec *) ap_find_command(const AnsiChar *name, const command_rec *cmds);
+//CORE_EXPORT(const command_rec *) ap_find_command_in_modules(const AnsiChar *cmd_name, module **mod);
 //CORE_EXPORT(void *) ap_set_config_vectors(cmd_parms *parms, void *config, module *mod);
-//CORE_EXPORT(const char *) ap_handle_command(cmd_parms *parms, void *config, const char *l);
+//CORE_EXPORT(const AnsiChar *) ap_handle_command(cmd_parms *parms, void *config, const AnsiChar *l);
 
 //#endif
 

+ 29 - 29
packages/httpd13/src/http_core.inc

@@ -79,10 +79,10 @@ function ap_allow_options(r: Prequest_rec): cint;
 function ap_allow_overrides(r: Prequest_rec): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_default_type(r: Prequest_rec): PChar;
+function ap_default_type(r: Prequest_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_document_root(r: Prequest_rec): PChar;
+function ap_document_root(r: Prequest_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
                                       { Don't use this!  If your request went
 				      * through a Userdir, or something like
@@ -90,19 +90,19 @@ function ap_document_root(r: Prequest_rec): PChar;
 				      * back-compatible...
                                       }
                                       
-function ap_get_remote_host(conn: Pconn_rec; dir_config: Pointer; type_: cint): PChar;
+function ap_get_remote_host(conn: Pconn_rec; dir_config: Pointer; type_: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_remote_logname(r: Prequest_rec): PChar;
+function ap_get_remote_logname(r: Prequest_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { Used for constructing self-referencing URLs, and things like SERVER_PORT,
  * and SERVER_NAME.
  }
-function ap_construct_url(p: Ppool; const uri: PChar; r: Prequest_rec): PChar;
+function ap_construct_url(p: Ppool; const uri: PAnsiChar; r: Prequest_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_server_name(r: Prequest_rec): PChar;
+function ap_get_server_name(r: Prequest_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_get_server_port(const r: Prequest_rec): cuint;
@@ -111,10 +111,10 @@ function ap_get_server_port(const r: Prequest_rec): cuint;
 function ap_get_limit_req_body(const r: Prequest_rec): culong;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_custom_response(r: Prequest_rec; status: cint; string_: PChar);
+procedure ap_custom_response(r: Prequest_rec; status: cint; string_: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_exists_config_define(name: PChar): cint;
+function ap_exists_config_define(name: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { Check if the current request is beyond the configured max. number of redirects or subrequests
@@ -134,12 +134,12 @@ function ap_is_recursion_limit_exceeded(const r: Prequest_rec): cint;
 type
   require_line = record
     method_mask: cint;
-    requirement: PChar;
+    requirement: PAnsiChar;
   end;
      
-{API_EXPORT(const char *) ap_auth_type (request_rec *);
-API_EXPORT(const char *) ap_auth_name (request_rec *);     
-API_EXPORT(const char *) ap_auth_nonce (request_rec *);
+{API_EXPORT(const AnsiChar *) ap_auth_type (request_rec *);
+API_EXPORT(const AnsiChar *) ap_auth_name (request_rec *);     
+API_EXPORT(const AnsiChar *) ap_auth_nonce (request_rec *);
 API_EXPORT(int) ap_satisfies (request_rec *r);
 API_EXPORT(const array_header *) ap_requires (request_rec *);    }
 
@@ -153,7 +153,7 @@ type
   interpreter_source_e = ( INTERPRETER_SOURCE_UNSET, INTERPRETER_SOURCE_REGISTRY,
    INTERPRETER_SOURCE_SHEBANG );
 
-function ap_get_win32_interpreter(const param1: Prequest_rec; param2: PPChar): file_type_e;
+function ap_get_win32_interpreter(const param1: Prequest_rec; param2: PPAnsiChar): file_type_e;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 {$endif}
 
@@ -165,19 +165,19 @@ function ap_get_win32_interpreter(const param1: Prequest_rec; param2: PPChar): f
  * the code that cares really is in http_core.c.  Also, another accessor.
  }
 
-//API_EXPORT(char *) ap_response_code_string (request_rec *r, int error_index);
+//API_EXPORT(AnsiChar *) ap_response_code_string (request_rec *r, int error_index);
 
 //extern API_VAR_EXPORT module core_module;
 
 { Per-directory configuration }
 
 type
-  allow_options_t = Char;
-  overrides_t = Char
+  allow_options_t = AnsiChar;
+  overrides_t = AnsiChar
   ;
 {
  * Bits of info that go into making an ETag for a file
- * document.  Why a long?  Because char historically
+ * document.  Why a long?  Because AnsiChar historically
  * proved too short for Options, and int can be different
  * sizes on different platforms.
  }
@@ -238,7 +238,7 @@ type
 
   core_dir_config = record
     { path of the directory/regex/etc.  see also d_is_fnmatch below }
-    d: PChar;
+    d: PAnsiChar;
     { the number of slashes in d }
     d_components: cuint;
 
@@ -259,22 +259,22 @@ type
      * goes untyped by other mechanisms before it slips out the door...
      }
     
-    ap_default_type: PChar;
+    ap_default_type: PAnsiChar;
   
     { Authentication stuff.  Groan... }
     
     satisfy: cint;
-    ap_auth_type: PChar;
-    ap_auth_name: PChar;
+    ap_auth_type: PAnsiChar;
+    ap_auth_name: PAnsiChar;
     ap_requires: Parray_header;
 
     { Custom response config. These can contain text or a URL to redirect to.
      * if response_code_strings is NULL then there are none in the config,
-     * if it's not null then it's allocated to sizeof(char*)*RESPONSE_CODES.
+     * if it's not null then it's allocated to sizeof(AnsiChar*)*RESPONSE_CODES.
      * This lets us do quick merges in merge_core_dir_configs().
      }
   
-    response_code_strings: PPChar; { from ErrorDocument, not from
+    response_code_strings: PPAnsiChar; { from ErrorDocument, not from
                                    * ap_custom_response()
                                    }
 
@@ -305,7 +305,7 @@ type
     { Moved up }
 
 //    unsigned add_default_charset : 2;
-    add_default_charset_name: PChar;
+    add_default_charset_name: PAnsiChar;
 
     { System Resource Control }
 {$ifdef RLIMIT_CPU}
@@ -367,7 +367,7 @@ type
     cgi_command_args: ap_flag_e;
 
     { Digest auth. }
-    ap_auth_nonce: PChar;
+    ap_auth_nonce: PAnsiChar;
 
   end;
 
@@ -377,18 +377,18 @@ type
   core_server_config = record
   
 {$ifdef GPROF}
-    gprof_dir: PChar;
+    gprof_dir: PAnsiChar;
 {$endif}
 
     { Name translations --- we want the core to be able to do *something*
      * so it's at least a minimally functional web server on its own (and
      * can be tested that way).  But let's keep it to the bare minimum:
      }
-    ap_document_root: PChar;
+    ap_document_root: PAnsiChar;
   
     { Access control }
 
-    access_name: PChar;
+    access_name: PAnsiChar;
     sec: Parray_header;
     sec_url: Parray_header;
 
@@ -416,7 +416,7 @@ const
 //CORE_EXPORT(void) ap_add_per_dir_conf (server_rec *s, void *dir_config);
 //CORE_EXPORT(void) ap_add_per_url_conf (server_rec *s, void *url_config);
 //CORE_EXPORT(void) ap_add_file_conf(core_dir_config *conf, void *url_config);
-//CORE_EXPORT_NONSTD(const char *) ap_limit_section (cmd_parms *cmd, void *dummy, const char *arg);
+//CORE_EXPORT_NONSTD(const AnsiChar *) ap_limit_section (cmd_parms *cmd, void *dummy, const AnsiChar *arg);
 
 {.$endif}
 

+ 12 - 12
packages/httpd13/src/http_log.inc

@@ -66,15 +66,15 @@ procedure ap_open_logs(s: Pserver_rec; p: PPool);
  * like "%s", followed by the string containing the untrusted data.
  }
 procedure ap_log_error(
- const file_: PChar; line, level: Integer;
- const s: Pserver_rec; const fmt: PChar; others: array of const);
+ const file_: PAnsiChar; line, level: Integer;
+ const s: Pserver_rec; const fmt: PAnsiChar; others: array of const);
  cdecl; external LibHTTPD;
 
 //			    __attribute__((format(printf,5,6)));
 
 procedure ap_log_rerror(
- const file_: PChar; line, level: Integer;
- const s: Prequest_rec; const fmt: PChar; others: array of const);
+ const file_: PAnsiChar; line, level: Integer;
+ const s: Prequest_rec; const fmt: PAnsiChar; others: array of const);
  cdecl; external LibHTTPD;
 
 //			    __attribute__((format(printf,5,6)));
@@ -82,25 +82,25 @@ procedure ap_log_rerror(
 procedure ap_error_log2stderr(s: Pserver_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_log_pid(p: PPool; fname: PChar);
+procedure ap_log_pid(p: PPool; fname: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { These are for legacy code, new code should use ap_log_error,
  * or ap_log_rerror.
  }
-{API_EXPORT(void) ap_log_error_old(const char *err, server_rec *s);
-API_EXPORT(void) ap_log_unixerr(const char *routine, const char *file,
-			     const char *msg, server_rec *s);
-API_EXPORT_NONSTD(void) ap_log_printf(const server_rec *s, const char *fmt, ...)
+{API_EXPORT(void) ap_log_error_old(const AnsiChar *err, server_rec *s);
+API_EXPORT(void) ap_log_unixerr(const AnsiChar *routine, const AnsiChar *file,
+			     const AnsiChar *msg, server_rec *s);
+API_EXPORT_NONSTD(void) ap_log_printf(const server_rec *s, const AnsiChar *fmt, ...)
 			    __attribute__((format(printf,2,3)));
-API_EXPORT(void) ap_log_reason(const char *reason, const char *fname,
+API_EXPORT(void) ap_log_reason(const AnsiChar *reason, const AnsiChar *fname,
 			    request_rec *r);}
 
 type
   piped_log = record
     p: PPool;
 //#if !defined(NO_RELIABLE_PIPED_LOGS) || defined(TPF)
-    program_: PChar;
+    program_: PAnsiChar;
     pid: cint;
     fds: array[1..2] of cint;
 //#else
@@ -110,7 +110,7 @@ type
   
   Ppiped_log = ^piped_log;
 
-procedure ap_open_piped_log(p: PPool; const program_: PChar);
+procedure ap_open_piped_log(p: PPool; const program_: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_close_piped_log(p: Ppiped_log): Ppiped_log;

+ 6 - 6
packages/httpd13/src/http_main.inc

@@ -70,13 +70,13 @@ procedure ap_start_shutdown();
 procedure ap_start_restart(param: cint);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_hard_timeout(p: PChar; r: Prequest_rec);
+procedure ap_hard_timeout(p: PAnsiChar; r: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_keepalive_timeout(p: PChar; r: Prequest_rec);
+procedure ap_keepalive_timeout(p: PAnsiChar; r: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_soft_timeout(p: PChar; r: Prequest_rec);
+procedure ap_soft_timeout(p: PAnsiChar; r: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 procedure ap_kill_timeout(r: Prequest_rec);
@@ -106,11 +106,11 @@ function ap_set_callback_and_alarm(fn: fn_t; x: cint): cuint;
 function ap_check_alarm(): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-{ void setup_signal_names(char *prefix);}
+{ void setup_signal_names(AnsiChar *prefix);}
 
 { functions for determination and setting of accept() mutexing }
-{char *ap_default_mutex_method(void);
-char *ap_init_mutex_method(char *t);}
+{AnsiChar *ap_default_mutex_method(void);
+AnsiChar *ap_init_mutex_method(AnsiChar *t);}
 
 {$ifndef NO_OTHER_CHILD}
 {

+ 11 - 11
packages/httpd13/src/http_protocol.inc

@@ -26,7 +26,7 @@ function ap_read_request(c: Pconn_rec): Prequest_rec;
 
 { Send a single HTTP header field }
 
-function ap_send_header_field(r: Prequest_rec; const fieldname, fieldval: PChar): cint;
+function ap_send_header_field(r: Prequest_rec; const fieldname, fieldval: PAnsiChar): cint;
  cdecl; external LibHTTPD;
 
 { Send the minimal part of an HTTP response header... but modules should be
@@ -81,7 +81,7 @@ function ap_set_keepalive(r: Prequest_rec): cint;
 function ap_rationalize_mtime(r: Prequest_rec; mtime: time_t): time_t;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_make_etag(r: Prequest_rec; force_weak: cint): PChar;
+function ap_make_etag(r: Prequest_rec; force_weak: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 procedure ap_set_etag(r: Prequest_rec);
@@ -126,7 +126,7 @@ function ap_send_mmap(mm: Pointer; r: Prequest_rec; offset, length: size_t): siz
 function ap_rputc(c: cint; r: Prequest_rec): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_rputs(const str: PChar; r: Prequest_rec): cint;
+function ap_rputs(const str: PAnsiChar; r: Prequest_rec): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_rwrite(const buf: Pointer; nbyte: cint; r: Prequest_rec): cint;
@@ -135,10 +135,10 @@ function ap_rwrite(const buf: Pointer; nbyte: cint; r: Prequest_rec): cint;
 function ap_rvputs(r: Prequest_rec; others: array of const): cint;
  cdecl; external LibHTTPD;
 
-function ap_vrprintf(r: Prequest_rec; const fmt: PChar; vlist: va_list): cint;
+function ap_vrprintf(r: Prequest_rec; const fmt: PAnsiChar; vlist: va_list): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_rprintf(r: Prequest_rec; const fmt: PChar; others: array of const): cint;
+function ap_rprintf(r: Prequest_rec; const fmt: PAnsiChar; others: array of const): cint;
  cdecl; external LibHTTPD;
 
 {				__attribute__((format(printf,2,3)));}
@@ -162,7 +162,7 @@ function ap_setup_client_block(r: Prequest_rec; read_policy: cint): cint;
 function ap_should_client_block(r: Prequest_rec): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_client_block(r: Prequest_rec; buffer: PChar; bufsiz: cint): clong;
+function ap_get_client_block(r: Prequest_rec; buffer: PAnsiChar; bufsiz: cint): clong;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_discard_request_body(r: Prequest_rec): cint;
@@ -207,7 +207,7 @@ procedure ap_note_basic_auth_failure(r: Prequest_rec);
 procedure ap_note_digest_auth_failure(r: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_basic_auth_pw(r: Prequest_rec; const pw: PPChar): cint;
+function ap_get_basic_auth_pw(r: Prequest_rec; const pw: PPAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 {
@@ -223,17 +223,17 @@ procedure ap_finalize_sub_req_protocol(sub_r: Prequest_rec);
 
 { This is also useful for putting sub_reqs and internal_redirects together }
 
-//CORE_EXPORT(void) ap_parse_uri(request_rec *r, const char *uri);
+//CORE_EXPORT(void) ap_parse_uri(request_rec *r, const AnsiChar *uri);
 
 { Get the method number associated with the given string, assumed to
  * contain an HTTP method.  Returns M_INVALID if not recognized.
  }
-function ap_method_number_of(const method: PChar): cint;
+function ap_method_number_of(const method: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getline(s: PChar; n: cint; in_: PBUFF; fold: cint): cint;
+function ap_getline(s: PAnsiChar; n: cint; in_: PBUFF; fold: cint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_chunk_size(b: PChar): clong;
+function ap_get_chunk_size(b: PAnsiChar): clong;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 

+ 5 - 5
packages/httpd13/src/http_request.inc

@@ -34,15 +34,15 @@
  * about which was allocated in its pool elsewhere before doing this.
  }
 
-function ap_sub_req_lookup_uri(const new_file: PChar;
+function ap_sub_req_lookup_uri(const new_file: PAnsiChar;
  const r: Prequest_rec): Prequest_rec;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_sub_req_lookup_file(const new_file: PChar;
+function ap_sub_req_lookup_file(const new_file: PAnsiChar;
  const r: Prequest_rec): Prequest_rec;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_sub_req_method_uri(const method, new_file: PChar;
+function ap_sub_req_method_uri(const method, new_file: PAnsiChar;
  const r: Prequest_rec): Prequest_rec;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
@@ -59,10 +59,10 @@ procedure ap_destroy_sub_req(r: Prequest_rec);
  * If so, call this from a handler, and then immediately return OK.
  }
 
-procedure ap_internal_redirect(const new_uri: PChar; param2: Prequest_rec);
+procedure ap_internal_redirect(const new_uri: PAnsiChar; param2: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_internal_redirect_handler(const new_uri: PChar; param2: Prequest_rec);
+procedure ap_internal_redirect_handler(const new_uri: PAnsiChar; param2: Prequest_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_some_auth_required(r: Prequest_rec): cint;

+ 3 - 3
packages/httpd13/src/http_vhost.inc

@@ -23,11 +23,11 @@ procedure ap_fini_vhost_config(p: PPool; main_server: Pserver_rec);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { handle addresses in <VirtualHost> statement }
-function ap_parse_vhost_addrs(p: PPool; const hostname: PChar; s: Pserver_rec): PChar;
+function ap_parse_vhost_addrs(p: PPool; const hostname: PAnsiChar; s: Pserver_rec): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 { handle NameVirtualHost directive }
-//function ap_set_name_virtual_host(cmd: Pcmd_parms; dummy: Pointer; arg: PChar): PChar;
+//function ap_set_name_virtual_host(cmd: Pcmd_parms; dummy: Pointer; arg: PAnsiChar): PAnsiChar;
 // cdecl; external LibHTTPD;
 
 { given an ip address only, give our best guess as to what vhost it is }
@@ -43,7 +43,7 @@ procedure ap_update_vhost_from_headers(r: Prequest_rec);
 { return 1 if the host:port matches any of the aliases of r->server
  * return 0 otherwise
  }
-function ap_matches_request_vhost(r: Prequest_rec; const host: PChar;
+function ap_matches_request_vhost(r: Prequest_rec; const host: PAnsiChar;
  port: cuint): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 

+ 121 - 121
packages/httpd13/src/httpd.inc

@@ -362,9 +362,9 @@ type
     SrvTk_PRODUCT_ONLY	{ eg: Apache }
   );
 
-//API_EXPORT(const char *) ap_get_server_version(void);
-//API_EXPORT(void) ap_add_version_component(const char *component);
-//API_EXPORT(const char *) ap_get_server_built(void);
+//API_EXPORT(const AnsiChar *) ap_get_server_version(void);
+//API_EXPORT(void) ap_add_version_component(const AnsiChar *component);
+//API_EXPORT(const AnsiChar *) ap_get_server_built(void);
 
 { Numeric release version identifier: MMNNFFRBB: major minor fix final beta
  * Always increases along the same track as the source branch.
@@ -583,7 +583,7 @@ type
   Phtaccess_result = ^htaccess_result;
   
   htaccess_result = record
-    dir: PChar;			{ the directory to which this applies }
+    dir: PAnsiChar;			{ the directory to which this applies }
     override_: cint;		{ the overrides allowed for the .htaccess file }
     htaccess: Pointer;		{ the configuration directives }
 { the next one, or NULL if no more; N.B. never change this }
@@ -624,25 +624,25 @@ type
      * protocol.c should ever touch...
      }
 
-    the_request: PChar;		{ First line of request, so we can log it }
+    the_request: PAnsiChar;		{ First line of request, so we can log it }
     assbackwards: cint;		{ HTTP/0.9, "simple" request }
     proxyreq: proxyreqtype;     { A proxy request (calculated during
 				 * post_read_request or translate_name) }
     header_only: cint;		{ HEAD request, as opposed to GET }
-    protocol: PChar;		{ Protocol, as given to us, or HTTP/0.9 }
+    protocol: PAnsiChar;		{ Protocol, as given to us, or HTTP/0.9 }
     proto_num: cint;		{ Number version of protocol; 1.1 = 1001 }
-    hostname: PChar;	{ Host, as set by full URI or Host: }
+    hostname: PAnsiChar;	{ Host, as set by full URI or Host: }
 
     request_time: time_t;	{ When the request started }
 
-    status_line: PChar;	{ Status line, if set by script }
+    status_line: PAnsiChar;	{ Status line, if set by script }
     status: cint;			{ In any case }
 
     { Request method, two ways; also, protocol, etc..  Outside of protocol.c,
      * look, but don't touch.
      }
 
-    method: PChar;		{ GET, HEAD, POST, etc. }
+    method: PAnsiChar;		{ GET, HEAD, POST, etc. }
     method_number: cint;		{ M_GET, M_POST, etc. }
 
     {
@@ -675,8 +675,8 @@ type
 
     chunked: cint;		{ sending chunked transfer-coding }
     byterange: cint;		{ number of byte ranges }
-    boundary: PChar;		{ multipart/byteranges boundary }
-    range: PChar;		{ The Range: header }
+    boundary: PAnsiChar;		{ multipart/byteranges boundary }
+    range: PAnsiChar;		{ The Range: header }
     clength: clong;		{ The "real" content length }
 
     remaining: clong;		{ bytes left to read }
@@ -707,14 +707,14 @@ type
      * content_languages MUST be lowercased strings.  They may be pointers
      * to static strings; they should not be modified in place.
      }
-    content_type: PChar;	{ Break these out --- we dispatch on 'em }
-    handler: PChar;    	        { What we *really* dispatch on           }
+    content_type: PAnsiChar;	{ Break these out --- we dispatch on 'em }
+    handler: PAnsiChar;    	        { What we *really* dispatch on           }
 
-    content_encoding: PChar;
-    content_language: PChar;	{ for back-compat. only -- do not use }
-    content_languages: Parray_header;	{ array of (char*) }
+    content_encoding: PAnsiChar;
+    content_language: PAnsiChar;	{ for back-compat. only -- do not use }
+    content_languages: Parray_header;	{ array of (AnsiChar*) }
 
-    vlist_validator: PChar;      { variant list validator (if negotiated) }
+    vlist_validator: PAnsiChar;      { variant list validator (if negotiated) }
 
     no_cache: cint;
     no_local_copy: cint;
@@ -723,11 +723,11 @@ type
      * or content-negotiation mapping).
      }
 
-    unparsed_uri: PChar;	{ the uri without any parsing performed }
-    uri: PChar;			{ the path portion of the URI }
-    filename: PChar;		{ filename if found, otherwise NULL }
-    path_info: PChar;
-    args: PChar;		{ QUERY_ARGS, if any }
+    unparsed_uri: PAnsiChar;	{ the uri without any parsing performed }
+    uri: PAnsiChar;			{ the path portion of the URI }
+    filename: PAnsiChar;		{ filename if found, otherwise NULL }
+    path_info: PAnsiChar;
+    args: PAnsiChar;		{ QUERY_ARGS, if any }
     finfo: Integer;//stat;      { ST_MODE set to zero if no such file }
     parsed_uri: uri_components;	{ components of uri, dismantled }
 
@@ -756,7 +756,7 @@ type
      * with WebDAV need to preserve filename case to make the Java compiler 
      * happy.
      }
-    case_preserved_filename: PChar;
+    case_preserved_filename: PAnsiChar;
 
 {$ifdef CHARSET_EBCDIC}
     { We don't want subrequests to modify our current conversion flags.
@@ -798,20 +798,20 @@ type
 
     local_addr: sockaddr_in;	{ local address }
     remote_addr: sockaddr_in;	{ remote address }
-    remote_ip: PChar;		{ Client's IP address }
-    remote_host: PChar;		{ Client's DNS name, if known.
+    remote_ip: PAnsiChar;		{ Client's IP address }
+    remote_host: PAnsiChar;		{ Client's DNS name, if known.
 				 * NULL if DNS hasn't been checked,
 				 * "" if it has and no address was found.
 				 * N.B. Only access this though
 				 * get_remote_host() }
-    remote_logname: PChar;	{ Only ever set if doing rfc1413 lookups.
+    remote_logname: PAnsiChar;	{ Only ever set if doing rfc1413 lookups.
 				 * N.B. Only access this through
 				 * get_remote_logname() }
-    user: PChar;			{ If an authentication check was made,
+    user: PAnsiChar;			{ If an authentication check was made,
 				 * this gets set to the user name.  We assume
 				 * that there's only one user per connection(!)
                                  }
-    ap_auth_type: PChar;		{ Ditto. }
+    ap_auth_type: PAnsiChar;		{ Ditto. }
 
 //    unsigned aborted:1;		{ Are we still talking? }
 //    signed int keepalive:2;	{ Are we using HTTP Keep-Alive?
@@ -820,8 +820,8 @@ type
 //    signed int double_reverse:2;{ have we done double-reverse DNS?
 //				 * -1 yes/failure, 0 not yet, 1 yes/success }
     keepalives: cint;		{ How many times have we used it? }
-    local_ip: PChar;		{ server IP address }
-    local_host: PChar;		{ used for ap_get_server_name when
+    local_ip: PAnsiChar;		{ server IP address }
+    local_host: PAnsiChar;		{ used for ap_get_server_name when
 				 * UseCanonicalName is set to DNS
 				 * (ignores setting of HostnameLookups) }
   end;
@@ -842,7 +842,7 @@ type
     next: Pserver_addr_rec;
     host_addr: in_addr; 	{ The bound address, for this server }
     host_port: cushort; 	{ The bound port, for this server }
-    virthost: PChar;		{ The name given in <VirtualHost> }
+    virthost: PAnsiChar;		{ The name given in <VirtualHost> }
   end;
 
   server_rec = record
@@ -850,23 +850,23 @@ type
     next: Pserver_rec;
 
     { description of where the definition came from }
-    defn_name: PChar;
+    defn_name: PAnsiChar;
     defn_line_number: cuint;
 
     { Full locations of server config info }
 
-    srm_confname: PChar;
-    access_confname: PChar;
+    srm_confname: PAnsiChar;
+    access_confname: PAnsiChar;
 
     { Contact information }
 
-    server_admin: PChar;
-    server_hostname: PChar;
+    server_admin: PAnsiChar;
+    server_hostname: PAnsiChar;
     port: cushort;	{ for redirects, etc. }
 
     { Log files --- note that transfer log is now in the modules... }
 
-    error_fname: PChar;
+    error_fname: PAnsiChar;
     error_log: Pointer; //FILE *
     loglevel: cint;
 
@@ -888,7 +888,7 @@ type
     keep_alive: cint;		{ Use persistent connections? }
     send_buffer_size: cint;	{ size of TCP send buffer (in bytes) }
 
-    path: PChar;		{ Pathname for ServerPath }
+    path: PAnsiChar;		{ Pathname for ServerPath }
     pathlen: cint;		{ Length of path }
 
     names: Parray_header;	{ Normal names for ServerAlias servers }
@@ -922,140 +922,140 @@ type
 //extern void ap_util_init(void);
 
 { Time }
-{extern API_VAR_EXPORT const char ap_month_snames[12][4];
-extern API_VAR_EXPORT const char ap_day_snames[7][4];}
+{extern API_VAR_EXPORT const AnsiChar ap_month_snames[12][4];
+extern API_VAR_EXPORT const AnsiChar ap_day_snames[7][4];}
 
 function ap_get_gmtoff(tz: Pcint): Ptm;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_time: PChar;
+function ap_get_time: PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_field_noparam(p: Ppool; const intype: PChar): PChar;
+function ap_field_noparam(p: Ppool; const intype: PAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_ht_time(p: Ppool; t: time_t; const fmt: PChar; gmt: cint): PChar;
+function ap_ht_time(p: Ppool; t: time_t; const fmt: PAnsiChar; gmt: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_gm_timestr_822(p: Ppool; t: time_t): PChar;
+function ap_gm_timestr_822(p: Ppool; t: time_t): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-{ String handling. The *_nc variants allow you to use non-const char **s as
-   arguments (unfortunately C won't automatically convert a char ** to a const
-   char **) }
+{ String handling. The *_nc variants allow you to use non-const AnsiChar **s as
+   arguments (unfortunately C won't automatically convert a AnsiChar ** to a const
+   AnsiChar **) }
 
-function ap_getword(p: Ppool; const line: PPChar; stop: Char): PChar;
+function ap_getword(p: Ppool; const line: PPAnsiChar; stop: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_nc(p: Ppool; line: PPChar; stop: Char): PChar;
+function ap_getword_nc(p: Ppool; line: PPAnsiChar; stop: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_white(p: Ppool; const line: PPChar): PChar;
+function ap_getword_white(p: Ppool; const line: PPAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_white_nc(p: Ppool; line: PPChar): PChar;
+function ap_getword_white_nc(p: Ppool; line: PPAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_nulls(p: Ppool; const line: PPChar; stop: Char): PChar;
+function ap_getword_nulls(p: Ppool; const line: PPAnsiChar; stop: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_nulls_nc(p: Ppool; line: PPChar; stop: Char): PChar;
+function ap_getword_nulls_nc(p: Ppool; line: PPAnsiChar; stop: AnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_conf(p: Ppool; const line: PPChar): PChar;
+function ap_getword_conf(p: Ppool; const line: PPAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_getword_conf_nc(p: Ppool; line: PPChar): PChar;
+function ap_getword_conf_nc(p: Ppool; line: PPAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 
-function ap_size_list_item(const field: PPChar; len: Pcint): PChar;
+function ap_size_list_item(const field: PPAnsiChar; len: Pcint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_get_list_item(p: Ppool; const field: PPChar): PChar;
+function ap_get_list_item(p: Ppool; const field: PPAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_find_list_item(p: Ppool; const line, tok: PChar): cint;
+function ap_find_list_item(p: Ppool; const line, tok: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 
-function ap_get_token(p: Ppool; const accept_line: PPChar; accept_white: cint): PChar;
+function ap_get_token(p: Ppool; const accept_line: PPAnsiChar; accept_white: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_find_token(p: Ppool; const line, tok: PChar): cint;
+function ap_find_token(p: Ppool; const line, tok: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_find_last_token(p: Ppool; const line, tok: PChar): cint;
+function ap_find_last_token(p: Ppool; const line, tok: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 
-function ap_unescape_url(url: PChar): cint;
+function ap_unescape_url(url: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_no2slash(name: PChar);
+procedure ap_no2slash(name: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_getparents(name: PChar);
+procedure ap_getparents(name: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_escape_path_segment(p: Ppool; const s: PChar): PChar;
+function ap_escape_path_segment(p: Ppool; const s: PAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_os_escape_path(p: Ppool; const path: PChar; partial: cint): PChar;
+function ap_os_escape_path(p: Ppool; const path: PAnsiChar; partial: cint): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 //#define ap_escape_uri(ppool,path) ap_os_escape_path(ppool,path,1)
 
-function ap_escape_html(p: Ppool; const s: PChar): PChar;
+function ap_escape_html(p: Ppool; const s: PAnsiChar): PAnsiChar;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-{API_EXPORT(char *) ap_construct_server(pool *p, const char *hostname,
+{API_EXPORT(AnsiChar *) ap_construct_server(pool *p, const AnsiChar *hostname,
 				    unsigned port, const request_rec *r);
-API_EXPORT(char *) ap_escape_logitem(pool *p, const char *str);
-API_EXPORT(size_t) ap_escape_errorlog_item(char *dest, const char *source,
+API_EXPORT(AnsiChar *) ap_escape_logitem(pool *p, const AnsiChar *str);
+API_EXPORT(size_t) ap_escape_errorlog_item(AnsiChar *dest, const AnsiChar *source,
                                            size_t buflen);
-API_EXPORT(char *) ap_escape_shell_cmd(pool *p, const char *s);
+API_EXPORT(AnsiChar *) ap_escape_shell_cmd(pool *p, const AnsiChar *s);
 
-API_EXPORT(int) ap_count_dirs(const char *path);
-API_EXPORT(char *) ap_make_dirstr_prefix(char *d, const char *s, int n);
-API_EXPORT(char *) ap_make_dirstr_parent(pool *p, const char *s);}
+API_EXPORT(int) ap_count_dirs(const AnsiChar *path);
+API_EXPORT(AnsiChar *) ap_make_dirstr_prefix(AnsiChar *d, const AnsiChar *s, int n);
+API_EXPORT(AnsiChar *) ap_make_dirstr_parent(pool *p, const AnsiChar *s);}
 { deprecated.  The previous two routines are preferred. }
-{API_EXPORT(char *) ap_make_dirstr(pool *a, const char *s, int n);
-API_EXPORT(char *) ap_make_full_path(pool *a, const char *dir, const char *f);
-
-API_EXPORT(int) ap_is_matchexp(const char *str);
-API_EXPORT(int) ap_strcmp_match(const char *str, const char *exp);
-API_EXPORT(int) ap_strcasecmp_match(const char *str, const char *exp);
-API_EXPORT(char *) ap_stripprefix(const char *bigstring, const char *prefix);
-API_EXPORT(char *) ap_strcasestr(const char *s1, const char *s2);
-API_EXPORT(char *) ap_pbase64decode(pool *p, const char *bufcoded);
-API_EXPORT(char *) ap_pbase64encode(pool *p, char *string); 
-API_EXPORT(char *) ap_uudecode(pool *p, const char *bufcoded);
-API_EXPORT(char *) ap_uuencode(pool *p, char *string); }
+{API_EXPORT(AnsiChar *) ap_make_dirstr(pool *a, const AnsiChar *s, int n);
+API_EXPORT(AnsiChar *) ap_make_full_path(pool *a, const AnsiChar *dir, const AnsiChar *f);
+
+API_EXPORT(int) ap_is_matchexp(const AnsiChar *str);
+API_EXPORT(int) ap_strcmp_match(const AnsiChar *str, const AnsiChar *exp);
+API_EXPORT(int) ap_strcasecmp_match(const AnsiChar *str, const AnsiChar *exp);
+API_EXPORT(AnsiChar *) ap_stripprefix(const AnsiChar *bigstring, const AnsiChar *prefix);
+API_EXPORT(AnsiChar *) ap_strcasestr(const AnsiChar *s1, const AnsiChar *s2);
+API_EXPORT(AnsiChar *) ap_pbase64decode(pool *p, const AnsiChar *bufcoded);
+API_EXPORT(AnsiChar *) ap_pbase64encode(pool *p, AnsiChar *string); 
+API_EXPORT(AnsiChar *) ap_uudecode(pool *p, const AnsiChar *bufcoded);
+API_EXPORT(AnsiChar *) ap_uuencode(pool *p, AnsiChar *string); }
 
 {$if defined(OS2) or defined(WINDOWS)}
-//API_EXPORT(char *) ap_double_quotes(pool *p, const char *str);
-//API_EXPORT(char *) ap_caret_escape_args(pool *p, const char *str);
+//API_EXPORT(AnsiChar *) ap_double_quotes(pool *p, const AnsiChar *str);
+//API_EXPORT(AnsiChar *) ap_caret_escape_args(pool *p, const AnsiChar *str);
 {$endif}
 
 {$ifdef OS2}
-void os2pathname(char *path);
+void os2pathname(AnsiChar *path);
 {$endif}
 
-{API_EXPORT(int)    ap_regexec(const regex_t *preg, const char *string,
+{API_EXPORT(int)    ap_regexec(const regex_t *preg, const AnsiChar *string,
                               size_t nmatch, regmatch_t pmatch[], int eflags);
 API_EXPORT(size_t) ap_regerror(int errcode, const regex_t *preg, 
-                               char *errbuf, size_t errbuf_size);
-API_EXPORT(char *) ap_pregsub(pool *p, const char *input, const char *source,
+                               AnsiChar *errbuf, size_t errbuf_size);
+API_EXPORT(AnsiChar *) ap_pregsub(pool *p, const AnsiChar *input, const AnsiChar *source,
                               size_t nmatch, regmatch_t pmatch[]);
 
-API_EXPORT(void) ap_content_type_tolower(char *);
-API_EXPORT(void) ap_str_tolower(char *);
-API_EXPORT(int) ap_ind(const char *, char);}	{ Sigh... }
-{API_EXPORT(int) ap_rind(const char *, char);
+API_EXPORT(void) ap_content_type_tolower(AnsiChar *);
+API_EXPORT(void) ap_str_tolower(AnsiChar *);
+API_EXPORT(int) ap_ind(const AnsiChar *, AnsiChar);}	{ Sigh... }
+{API_EXPORT(int) ap_rind(const AnsiChar *, AnsiChar);
 
-API_EXPORT(char *) ap_escape_quotes (pool *p, const char *instring);
-API_EXPORT(void) ap_remove_spaces(char *dest, char *src);}
+API_EXPORT(AnsiChar *) ap_escape_quotes (pool *p, const AnsiChar *instring);
+API_EXPORT(void) ap_remove_spaces(AnsiChar *dest, AnsiChar *src);}
 
 { Common structure for reading of config files / passwd files etc. }
 type
@@ -1073,51 +1073,51 @@ type
     getstr: getstr_t;   { a fgets()-like function }
     close: close_t;	{ a close hander function }
     param: Pointer;	{ the argument passed to getch/getstr/close }
-    name: PChar;	{ the filename / description }
+    name: PAnsiChar;	{ the filename / description }
     line_number: cuint;	{ current line number, starting at 1 }
   end;
 
 { Open a configfile_t as FILE, return open configfile_t struct pointer }
-//API_EXPORT(configfile_t *) ap_pcfg_openfile(pool *p, const char *name);
+//API_EXPORT(configfile_t *) ap_pcfg_openfile(pool *p, const AnsiChar *name);
 
 { Allocate a configfile_t handle with user defined functions and params }
-//API_EXPORT(configfile_t *) ap_pcfg_open_custom(pool *p, const char *descr,
+//API_EXPORT(configfile_t *) ap_pcfg_open_custom(pool *p, const AnsiChar *descr,
 //    void *param,
 //    int( *getc_func)(void*),
 //    void *( *gets_func) (void *buf, size_t bufsiz, void *param),
 //    int( *close_func)(void *param));
 
 { Read one line from open configfile_t, strip LF, increase line number }
-//API_EXPORT(int) ap_cfg_getline(char *buf, size_t bufsize, configfile_t *cfp);
+//API_EXPORT(int) ap_cfg_getline(AnsiChar *buf, size_t bufsize, configfile_t *cfp);
 
-{ Read one char from open configfile_t, increase line number upon LF }
+{ Read one AnsiChar from open configfile_t, increase line number upon LF }
 //API_EXPORT(int) ap_cfg_getc(configfile_t *cfp);
 
 { Detach from open configfile_t, calling the close handler }
 //API_EXPORT(int) ap_cfg_closefile(configfile_t *cfp);
 
 {$ifdef NEED_STRERROR}
-//char *strerror(int err);
+//AnsiChar *strerror(int err);
 {$endif}
 
 { Misc system hackery }
 
-function ap_uname2id(const name: PChar): uid_t;
+function ap_uname2id(const name: PAnsiChar): uid_t;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_gname2id(const name: PChar): gid_t;
+function ap_gname2id(const name: PAnsiChar): gid_t;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_is_directory(const name: PChar): cint;
+function ap_is_directory(const name: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-function ap_is_rdirectory(const name: PChar): cint;
+function ap_is_rdirectory(const name: PAnsiChar): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 function ap_can_exec(const stat: Pointer): cint;
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
-procedure ap_chdir_file(const file_: PChar);
+procedure ap_chdir_file(const file_: PAnsiChar);
  {$IFDEF WINDOWS} stdcall; {$ELSE} cdecl; {$ENDIF} external LibHTTPD;
 
 {$ifndef HAVE_CANONICAL_FILENAME}
@@ -1128,15 +1128,15 @@ procedure ap_chdir_file(const file_: PChar);
 #define ap_os_case_canonical_filename(p,f)  (f)
 #define ap_os_systemcase_filename(p,f)  (f)}
 {$else}
-//API_EXPORT(char *) ap_os_canonical_filename(pool *p, const char *file);
+//API_EXPORT(AnsiChar *) ap_os_canonical_filename(pool *p, const AnsiChar *file);
 {$ifdef WINDOWS}
-//API_EXPORT(char *) ap_os_case_canonical_filename(pool *pPool, const char *szFile);
-//API_EXPORT(char *) ap_os_systemcase_filename(pool *pPool, const char *szFile);
+//API_EXPORT(AnsiChar *) ap_os_case_canonical_filename(pool *pPool, const AnsiChar *szFile);
+//API_EXPORT(AnsiChar *) ap_os_systemcase_filename(pool *pPool, const AnsiChar *szFile);
 {$else}{$ifdef OS2}
-//API_EXPORT(char *) ap_os_case_canonical_filename(pool *pPool, const char *szFile);
-//API_EXPORT(char *) ap_os_systemcase_filename(pool *pPool, const char *szFile);
+//API_EXPORT(AnsiChar *) ap_os_case_canonical_filename(pool *pPool, const AnsiChar *szFile);
+//API_EXPORT(AnsiChar *) ap_os_systemcase_filename(pool *pPool, const AnsiChar *szFile);
 {$else}{$ifdef NETWARE}
-//API_EXPORT(char *) ap_os_case_canonical_filename(pool *pPool, const char *szFile);
+//API_EXPORT(AnsiChar *) ap_os_case_canonical_filename(pool *pPool, const AnsiChar *szFile);
 //#define ap_os_systemcase_filename(p,f) ap_os_case_canonical_filename(p,f)
 {$else}
 //#define ap_os_case_canonical_filename(p,f) ap_os_canonical_filename(p,f)
@@ -1151,8 +1151,8 @@ procedure ap_chdir_file(const file_: PChar);
 //API_EXPORT(int)    ap_checkconv_in(struct request_rec *r); { for uploads }
 {$endif} {#ifdef CHARSET_EBCDIC}
 
-{API_EXPORT(char *) ap_get_local_host(pool *);
-API_EXPORT(unsigned long) ap_get_virthost_addr(char *hostname, unsigned short *port);
+{API_EXPORT(AnsiChar *) ap_get_local_host(pool *);
+API_EXPORT(unsigned long) ap_get_virthost_addr(AnsiChar *hostname, unsigned short *port);
 
 extern API_VAR_EXPORT time_t ap_restart_time;}
 
@@ -1167,7 +1167,7 @@ extern API_VAR_EXPORT time_t ap_restart_time;}
  * Only the low slack line is used by default.  If HIGH_SLACK_LINE is defined
  * then an attempt is also made to keep all non-FILE * files above the high
  * slack line.  This is to work around a Solaris C library limitation, where it
- * uses an unsigned char to store the file descriptor.
+ * uses an unsigned AnsiChar to store the file descriptor.
  }
 
 const
@@ -1190,12 +1190,12 @@ const
   AP_SLACK_HIGH	= 2;
 #endif
 
-API_EXPORT(char *) ap_escape_quotes(pool *p, const char *instr);}
+API_EXPORT(AnsiChar *) ap_escape_quotes(pool *p, const AnsiChar *instr);}
 
 {
  * Redefine assert() to something more useful for an Apache...
  }
-{API_EXPORT(void) ap_log_assert(const char *szExp, const char *szFile, int nLine)
+{API_EXPORT(void) ap_log_assert(const AnsiChar *szExp, const AnsiChar *szFile, int nLine)
 			    __attribute__((noreturn));
 #define ap_assert(exp) ((exp) ? (void)0 : ap_log_assert(#exp,__FILE__,__LINE__))}
 
@@ -1226,7 +1226,7 @@ extern int raise_sigstop_flags;
 #define RAISE_SIGSTOP(x)
 #endif
 
-API_EXPORT(extern const char *) ap_psignature(const char *prefix, request_rec *r);}
+API_EXPORT(extern const AnsiChar *) ap_psignature(const AnsiChar *prefix, request_rec *r);}
 
   { strtoul does not exist on sunos4. }
 

+ 3 - 3
packages/httpd13/src/httpd.pas

@@ -129,7 +129,7 @@ begin
   Result := number mod 1000;
 end;
 
-{function ap_escape_uri(p: Papr_pool_t; const path: PChar): PChar;
+{function ap_escape_uri(p: Papr_pool_t; const path: PAnsiChar): PAnsiChar;
 begin
   Result := ap_os_escape_path(p, path, 1);
 end;}
@@ -143,7 +143,7 @@ begin
   mod_.version := MODULE_MAGIC_NUMBER_MAJOR;
   mod_.minor_version := MODULE_MAGIC_NUMBER_MINOR;
   mod_.module_index := -1;
-//  mod_.name: PChar;
+//  mod_.name: PAnsiChar;
   mod_.dynamic_load_handle := nil;
   mod_.next := nil;
   mod_.magic := MODULE_MAGIC_COOKIE;
@@ -155,7 +155,7 @@ end;
 //  mod_.version := MODULE_MAGIC_NUMBER_MAJOR;
 //  mod_.minor_version := MODULE_MAGIC_NUMBER_MINOR;
 //  mod_.module_index := -1;
-//  mod_.name: PChar;
+//  mod_.name: PAnsiChar;
 //  mod_.dynamic_load_handle := nil;
 //  mod_.next := nil;
 //  mod_.magic := MODULE_MAGIC_COOKIE;

+ 3 - 3
packages/httpd13/src/readdir.inc

@@ -40,7 +40,7 @@ type
     d_ino: clong;                         { inode (always 1 in WIN32) }
     d_off: off_t;                         { offset to this dirent }
     d_reclen: cushort;                    { length of d_name }
-    d_name: array[0.._MAX_FNAME] of Char;    { filename (null terminated) }
+    d_name: array[0.._MAX_FNAME] of AnsiChar;    { filename (null terminated) }
   end;
 
 { typedef DIR - not the same as Unix }
@@ -50,14 +50,14 @@ type
     finished: cshort;              { 1 if there are not more files }
 //    struct _finddata_t fileinfo; { from _findfirst/_findnext }
     fileinfo: Pointer;             { from _findfirst/_findnext }
-    dir: PChar;                    { the dir we are reading }
+    dir: PAnsiChar;                    { the dir we are reading }
     dent: dirent;                  { the dirent to return }
   end;
 
   PDIR = ^DIR;
   
 { Function prototypes }
-{API_EXPORT(DIR *) opendir(const char *);
+{API_EXPORT(DIR *) opendir(const AnsiChar *);
 API_EXPORT(struct dirent *) readdir(DIR *);
 API_EXPORT(int) closedir(DIR *);}
 

+ 15 - 15
packages/httpd13/src/util_uri.inc

@@ -20,7 +20,7 @@
 
 type
   schemes_t = record
-    name: PChar;
+    name: PAnsiChar;
     default_port: cushort;
   end;
 
@@ -49,15 +49,15 @@ type
   Phostent = ^hostent;
 
   uri_components = record
-    scheme: PChar;		{ scheme ("http"/"ftp"/...) }
-    hostinfo: PChar;            { combined [user[:password]@]host[:port] }
-    user: PChar;		{ user name, as in http://user:passwd@host:port/ }
-    password: PChar;		{ password, as in http://user:passwd@host:port/ }
-    hostname: PChar;		{ hostname from URI (or from Host: header) }
-    port_str: PChar;		{ port string (integer representation is in "port") }
-    path: PChar;		{ the request path (or "/" if only scheme://host was given) }
-    query: PChar;		{ Everything after a '?' in the path, if present }
-    fragment: PChar;		{ Trailing "#fragment" string, if present }
+    scheme: PAnsiChar;		{ scheme ("http"/"ftp"/...) }
+    hostinfo: PAnsiChar;            { combined [user[:password]@]host[:port] }
+    user: PAnsiChar;		{ user name, as in http://user:passwd@host:port/ }
+    password: PAnsiChar;		{ password, as in http://user:passwd@host:port/ }
+    hostname: PAnsiChar;		{ hostname from URI (or from Host: header) }
+    port_str: PAnsiChar;		{ port string (integer representation is in "port") }
+    path: PAnsiChar;		{ the request path (or "/" if only scheme://host was given) }
+    query: PAnsiChar;		{ Everything after a '?' in the path, if present }
+    fragment: PAnsiChar;		{ Trailing "#fragment" string, if present }
 
     hostent: Phostent;
 
@@ -71,14 +71,14 @@ type
   end;
 
 { util_uri.c }
-{API_EXPORT(unsigned short) ap_default_port_for_scheme(const char *scheme_str);
+{API_EXPORT(unsigned short) ap_default_port_for_scheme(const AnsiChar *scheme_str);
 API_EXPORT(unsigned short) ap_default_port_for_request(const request_rec *r);
 API_EXPORT(struct hostent *) ap_pduphostent(pool *p, const struct hostent *hp);
-API_EXPORT(struct hostent *) ap_pgethostbyname(pool *p, const char *hostname);
-API_EXPORT(char *) ap_unparse_uri_components(pool *p, const uri_components *uptr,
+API_EXPORT(struct hostent *) ap_pgethostbyname(pool *p, const AnsiChar *hostname);
+API_EXPORT(AnsiChar *) ap_unparse_uri_components(pool *p, const uri_components *uptr,
     unsigned flags);
-API_EXPORT(int) ap_parse_uri_components(pool *p, const char *uri, uri_components *uptr);
-API_EXPORT(int) ap_parse_hostinfo_components(pool *p, const char *hostinfo, uri_components *uptr);}
+API_EXPORT(int) ap_parse_uri_components(pool *p, const AnsiChar *uri, uri_components *uptr);
+API_EXPORT(int) ap_parse_hostinfo_components(pool *p, const AnsiChar *hostinfo, uri_components *uptr);}
 { called by the core in main() }
 //extern void ap_util_uri_init(void);
 

+ 11 - 11
packages/httpd13/src/win32_os.inc

@@ -50,7 +50,7 @@ const
  }
 
 { temporarily replace crypt }
-{ char *crypt(const char *pw, const char *salt); }
+{ AnsiChar *crypt(const AnsiChar *pw, const AnsiChar *salt); }
 //#define crypt(buf,salt)	    (buf)
 
 { Although DIR_TYPE is dirent (see nt/readdir.h) we need direct.h for
@@ -83,7 +83,7 @@ type
 { modified to match declaration in sys/stat.h }
   mode_t = cushort;
 {$endif}
-  caddr_t = PChar;
+  caddr_t = PAnsiChar;
 
 {
 Define export types. API_EXPORT_NONSTD is a nasty hack to avoid having to declare
@@ -138,7 +138,7 @@ every configuration function as __stdcall.
 {$define NO_OTHER_CHILD}
 {$define NO_RELIABLE_PIPED_LOGS}
 
-//__inline int ap_os_is_path_absolute(const char *file)
+//__inline int ap_os_is_path_absolute(const AnsiChar *file)
 {
   For now, just do the same check that http_request.c and mod_alias.c
    * do.
@@ -147,23 +147,23 @@ every configuration function as __stdcall.
 }
 
 {#define stat(f,ps)  os_stat(f,ps)
-API_EXPORT(int) os_stat(const char *szPath,struct stat *pStat);
+API_EXPORT(int) os_stat(const AnsiChar *szPath,struct stat *pStat);
 
-API_EXPORT(int) os_strftime(char *s, size_t max, const char *format, const struct tm *tm);
+API_EXPORT(int) os_strftime(AnsiChar *s, size_t max, const AnsiChar *format, const struct tm *tm);
 
 #define _spawnv(mode,cmdname,argv)	    os_spawnv(mode,cmdname,argv)
 #define spawnv(mode,cmdname,argv)	    os_spawnv(mode,cmdname,argv)
-API_EXPORT(int) os_spawnv(int mode,const char *cmdname,const char *const *argv);
+API_EXPORT(int) os_spawnv(int mode,const AnsiChar *cmdname,const AnsiChar *const *argv);
 #define _spawnve(mode,cmdname,argv,envp)    os_spawnve(mode,cmdname,argv,envp)
 #define spawnve(mode,cmdname,argv,envp)	    os_spawnve(mode,cmdname,argv,envp)
-API_EXPORT(int) os_spawnve(int mode,const char *cmdname,const char *const *argv,const char *const *envp);
+API_EXPORT(int) os_spawnve(int mode,const AnsiChar *cmdname,const AnsiChar *const *argv,const AnsiChar *const *envp);
 #define _spawnle			    os_spawnle
 #define spawnle				    os_spawnle
-API_EXPORT_NONSTD(int) os_spawnle(int mode,const char *cmdname,...);}
+API_EXPORT_NONSTD(int) os_spawnle(int mode,const AnsiChar *cmdname,...);}
 
 { OS-dependent filename routines in util_win32.c }
 
-//API_EXPORT(int) ap_os_is_filename_valid(const char *file);
+//API_EXPORT(int) ap_os_is_filename_valid(const AnsiChar *file);
 
 { Abstractions for dealing with shared object files (DLLs on Win32).
  * These are used by mod_so.c
@@ -173,8 +173,8 @@ API_EXPORT_NONSTD(int) os_spawnle(int mode,const char *cmdname,...);}
 #define ap_os_dso_unload(l) FreeLibrary(l)
 #define ap_os_dso_sym(h,s)  GetProcAddress(h,s)
 
-API_EXPORT(ap_os_dso_handle_t) ap_os_dso_load(const char *);
-API_EXPORT(const char *) ap_os_dso_error(void);}
+API_EXPORT(ap_os_dso_handle_t) ap_os_dso_load(const AnsiChar *);
+API_EXPORT(const AnsiChar *) ap_os_dso_error(void);}
 
 { Other ap_os_ routines not used by this platform }
 //#define ap_os_kill(pid, sig)                kill(pid, sig)