Browse code

0.99.3 - bb11954 - adding pid check to fanotify event verification to ensure we ignore events triggered by our own process

Mickey Sola authored on 2017/11/21 02:32:08
Showing 1 changed files
... ...
@@ -809,6 +809,10 @@ onas_fan_checkowner (int pid, const struct optstruct *opts)
809 809
     STATBUF sb;
810 810
     const struct optstruct *opt;
811 811
 
812
+    if (pid == (int) getpid()) {
813
+        return 1;
814
+    }
815
+
812 816
     if (!(opt = optget (opts, "OnAccessExcludeUID"))->enabled)
813 817
         return 0;
814 818