Author: jhb
Date: Fri Dec 16 20:10:00 2011
New Revision: 228593
URL: http://svn.freebsd.org/changeset/base/228593

Log:
  Fire a kevent if necessary after seeking on a regular file.  This fixes a
  case where a kevent would not fire on a regular file if an application read
  to EOF and then seeked backwards into the file.
  
  Reviewed by:  kib
  MFC after:    2 weeks

Modified:
  head/sys/kern/vfs_syscalls.c

Modified: head/sys/kern/vfs_syscalls.c
==============================================================================
--- head/sys/kern/vfs_syscalls.c        Fri Dec 16 19:39:49 2011        
(r228592)
+++ head/sys/kern/vfs_syscalls.c        Fri Dec 16 20:10:00 2011        
(r228593)
@@ -2050,6 +2050,7 @@ sys_lseek(td, uap)
        if (error != 0)
                goto drop;
        fp->f_offset = offset;
+       VFS_KNOTE_UNLOCKED(vp, 0);
        *(off_t *)(td->td_retval) = fp->f_offset;
 drop:
        fdrop(fp, td);
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"

Reply via email to