Alexander Bluhm(alexander.bl...@gmx.net) on 2019.12.24 23:11:12 +0100:
> Hi,
> 
> Use FOREACH macro for mnt_vnodelist.
> 
> ok?

ok benno@

> 
> bluhm
> 
> Index: nfs/nfs_subs.c
> ===================================================================
> RCS file: /data/mirror/openbsd/cvs/src/sys/nfs/nfs_subs.c,v
> retrieving revision 1.139
> diff -u -p -r1.139 nfs_subs.c
> --- nfs/nfs_subs.c    30 Nov 2018 09:24:57 -0000      1.139
> +++ nfs/nfs_subs.c    24 Dec 2019 21:54:49 -0000
> @@ -1515,10 +1515,9 @@ nfs_clearcommit(struct mount *mp)
> 
>       s = splbio();
>  loop:
> -     for (vp = LIST_FIRST(&mp->mnt_vnodelist); vp != NULL; vp = nvp) {
> +     LIST_FOREACH_SAFE(vp, &mp->mnt_vnodelist, v_mntvnodes, nvp) {
>               if (vp->v_mount != mp)  /* Paranoia */
>                       goto loop;
> -             nvp = LIST_NEXT(vp, v_mntvnodes);
>               LIST_FOREACH_SAFE(bp, &vp->v_dirtyblkhd, b_vnbufs, nbp) {
>                       if ((bp->b_flags & (B_BUSY | B_DELWRI | B_NEEDCOMMIT))
>                           == (B_DELWRI | B_NEEDCOMMIT))
> 

Reply via email to