Author: truckman
Date: Mon May 23 04:52:27 2016
New Revision: 300451
URL: https://svnweb.freebsd.org/changeset/base/300451

Log:
  MFC r299897
  
  NULL releasedfl after calling deallocate_file_lock() which frees it
  to avoid a use-after-free error in the debuglog() call at the top
  of the loop.
  
  Reported by:  Coverity
  CID:          1006080

Modified:
  stable/10/usr.sbin/rpc.lockd/lockd_lock.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/rpc.lockd/lockd_lock.c
==============================================================================
--- stable/10/usr.sbin/rpc.lockd/lockd_lock.c   Mon May 23 04:50:01 2016        
(r300450)
+++ stable/10/usr.sbin/rpc.lockd/lockd_lock.c   Mon May 23 04:52:27 2016        
(r300451)
@@ -1600,6 +1600,7 @@ unlock_partialfilelock(const struct file
                                 */
 
                                deallocate_file_lock(releasedfl);
+                               releasedfl = NULL;
                        }
                }
 
_______________________________________________
svn-src-stable-10@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"

Reply via email to