Date: Wed, 20 Nov 2013 11:47:51 +0000 (UTC) From: Andriy Gapon <avg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r258388 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <201311201147.rAKBlphC073971@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: avg Date: Wed Nov 20 11:47:50 2013 New Revision: 258388 URL: http://svnweb.freebsd.org/changeset/base/258388 Log: MFV r258377: 4088 use after free in arc_release() illumos/illumos-gate@ccc22e130479b5bd7c0002267fee1e0602d3f772 MFC after: 5 days Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed Nov 20 11:10:23 2013 (r258387) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed Nov 20 11:47:50 2013 (r258388) @@ -3540,6 +3540,7 @@ arc_release(arc_buf_t *buf, void *tag) if (l2hdr) { mutex_enter(&l2arc_buflist_mtx); hdr->b_l2hdr = NULL; + list_remove(l2hdr->b_dev->l2ad_buflist, hdr); } buf_size = hdr->b_size; @@ -3627,7 +3628,6 @@ arc_release(arc_buf_t *buf, void *tag) ARCSTAT_INCR(arcstat_l2_asize, -l2hdr->b_asize); trim_map_free(l2hdr->b_dev->l2ad_vdev, l2hdr->b_daddr, hdr->b_size, 0); - list_remove(l2hdr->b_dev->l2ad_buflist, hdr); kmem_free(l2hdr, sizeof (l2arc_buf_hdr_t)); ARCSTAT_INCR(arcstat_l2_size, -buf_size); mutex_exit(&l2arc_buflist_mtx);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201311201147.rAKBlphC073971>