aboutsummaryrefslogtreecommitdiff
path: root/security/l0pht-watch
diff options
context:
space:
mode:
authorJonathan Lemon <jlemon@FreeBSD.org>2000-07-18 21:53:39 +0000
committerJonathan Lemon <jlemon@FreeBSD.org>2000-07-18 21:53:39 +0000
commitb0362380e5b0ab179703f37ebc51ee10b44657b5 (patch)
treef632b51c5ea2cbca761851163bc33d2584693948 /security/l0pht-watch
parentca68c777efe0ec293ede68fb632570ce621e58f8 (diff)
downloadports-b0362380e5b0ab179703f37ebc51ee10b44657b5.tar.gz
ports-b0362380e5b0ab179703f37ebc51ee10b44657b5.zip
Notes
Diffstat (limited to 'security/l0pht-watch')
-rw-r--r--security/l0pht-watch/files/patch-ab28
1 files changed, 13 insertions, 15 deletions
diff --git a/security/l0pht-watch/files/patch-ab b/security/l0pht-watch/files/patch-ab
index a84ef83adfc4..eb73a0d7650b 100644
--- a/security/l0pht-watch/files/patch-ab
+++ b/security/l0pht-watch/files/patch-ab
@@ -1,14 +1,13 @@
---- check_tmp.c.orig Fri Sep 24 13:33:35 1999
-+++ check_tmp.c Mon May 22 23:49:21 2000
-@@ -37,7 +37,14 @@
+--- check_tmp.c.orig Fri Sep 24 15:33:35 1999
++++ check_tmp.c Tue Jul 18 16:18:59 2000
+@@ -37,7 +37,13 @@
char error_buffer[256];
#endif
#endif
-
+
-+#if (__FreeBSD_version >= 500001) || (__FreeBSD_version >= 400019 && __FreeBSD_version < 500000)
++#if (__FreeBSD_version >= 500011) || (__FreeBSD_version >= 410000 && __FreeBSD_version < 500000)
+ struct kevent ev;
-+ struct kevent *evp;
+ int fd;
+ struct timespec ts = { 0, 0 };
+ int kq = -1;
@@ -16,11 +15,11 @@
struct listStruct *list = NULL;
-@@ -178,6 +185,22 @@
+@@ -178,6 +184,21 @@
exit(1);
}
-+#if (__FreeBSD_version >= 500001) || (__FreeBSD_version >= 400019 && __FreeBSD_version < 500000)
++#if (__FreeBSD_version >= 500011) || (__FreeBSD_version >= 410000 && __FreeBSD_version < 500000)
+ /* Set up the KQ on the target directory */
+ fd = dirfd(dirp);
+
@@ -32,25 +31,24 @@
+ ev.filter = EVFILT_VNODE;
+ ev.flags = EV_ADD | EV_ENABLE | EV_CLEAR;
+ ev.fflags = NOTE_WRITE;
-+ evp = &ev;
-+ kevent(kq, 1, &evp, 0, NULL, &ts);
++ kevent(kq, &ev, 1, NULL, 0, &ts);
+#endif
+
/* steup the first element of the list */
while ((dp = readdir(dirp)) != NULL){
if (!list) /* first time */
-@@ -266,6 +289,10 @@
+@@ -266,6 +287,10 @@
rewinddir(dirp);
while (1){
+
-+#if (__FreeBSD_version >= 500001) || (__FreeBSD_version >= 400019 && __FreeBSD_version < 500000)
++#if (__FreeBSD_version >= 500011) || (__FreeBSD_version >= 410000 && __FreeBSD_version < 500000)
+ if (ev.fflags & NOTE_WRITE) {
+#endif
while ((dp = readdir(dirp)) != NULL){
if (!(checknode(list, watchdir, dp->d_name))){
if (replacewatchflag){
-@@ -352,11 +379,22 @@
+@@ -352,11 +377,22 @@
/* closedir(dirp); */
}
}
@@ -61,12 +59,12 @@
list = prunelist(list);
rewinddir(dirp);
+
-+#if (__FreeBSD_version >= 500001) || (__FreeBSD_version >= 400019 && __FreeBSD_version < 500000)
++#if (__FreeBSD_version >= 500011) || (__FreeBSD_version >= 410000 && __FreeBSD_version < 500000)
+ /* Reset event so we don't trigger on the rewinddir */
-+ kevent(kq, 1, &evp, 0, NULL, &ts);
++ kevent(kq, &ev, 1, NULL, 0, &ts);
+
+ /* Block until the directory changes */
-+ if (kevent(kq, 0, NULL, 1, &ev, NULL) < 0)
++ if (kevent(kq, NULL, 0, &ev, 1, NULL) < 0)
+ err(1, "kevent");
+
+ }