1998-12-08 Martin Buchholz <martin(a)xemacs.org>
* windowsnt.h: Remove `support' for using index and rindex
* filelock.c (current_lock_owner):
- Change uses of index -> strchr, rindex -> strrchr
--- src/filelock.c.old
+++ src/filelock.c
@@ -157,9 +157,6 @@
static int
current_lock_owner (lock_info_type *owner, char *lfname)
{
-#ifndef index
- extern char *rindex (), *index ();
-#endif
int o, p, len, ret;
int local_owner = 0;
char *at, *dot;
@@ -195,8 +192,8 @@
/* Parse USER(a)HOST.PID. If can't parse, return -1. */
/* The USER is everything before the first @. */
- at = index (lfinfo, '@');
- dot = rindex (lfinfo, '.');
+ at = strchr (lfinfo, '@');
+ dot = strrchr (lfinfo, '.');
if (!at || !dot) {
xfree (lfinfo);
return -1;
--- src/s/windowsnt.h.old
+++ src/s/windowsnt.h
@@ -269,8 +269,8 @@
#define putw _putw
#define umask _umask
/* #define utime _utime */
-#define index strchr
-#define rindex strrchr
+/* #define index strchr */
+/* #define rindex strrchr */
#define read _read
#define write _write
#define getcwd _getcwd