Author: bdrewery
Date: Fri Jan 29 00:44:28 2016
New Revision: 295026
URL: https://svnweb.freebsd.org/changeset/base/295026

Log:
  filemon_open: Don't record a process to trace here.
  
  Only ioctl(FILEMON_SET_PID) should be setting the process-to-be-traced.
  
  MFC after:    2 weeks
  Sponsored by: EMC / Isilon Storage Division

Modified:
  head/sys/dev/filemon/filemon.c

Modified: head/sys/dev/filemon/filemon.c
==============================================================================
--- head/sys/dev/filemon/filemon.c      Fri Jan 29 00:29:32 2016        
(r295025)
+++ head/sys/dev/filemon/filemon.c      Fri Jan 29 00:44:28 2016        
(r295026)
@@ -221,10 +221,9 @@ filemon_open(struct cdev *dev, int oflag
                filemon = malloc(sizeof(struct filemon), M_FILEMON,
                    M_WAITOK | M_ZERO);
                sx_init(&filemon->lock, "filemon");
+               filemon->pid = -1;
        }
 
-       filemon->pid = curproc->p_pid;
-
        devfs_set_cdevpriv(filemon, filemon_dtr);
 
        /* Get exclusive write access. */
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to