Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Oct 2017 08:07:29 -0700
From:      Ngie Cooper <yaneurabeya@gmail.com>
To:        Emmanuel Vadot <manu@FreeBSD.org>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r324257 - head/usr.sbin/mountd
Message-ID:  <C3FC78EB-1445-4AB4-845B-1E5491C77241@gmail.com>
In-Reply-To: <201710040843.v948huhc028834@repo.freebsd.org>
References:  <201710040843.v948huhc028834@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help


> On Oct 4, 2017, at 01:43, Emmanuel Vadot <manu@FreeBSD.org> wrote:
> 
> Author: manu
> Date: Wed Oct  4 08:43:56 2017
> New Revision: 324257
> URL: https://svnweb.freebsd.org/changeset/base/324257
> 
> Log:
>  mountd: Convert exportlist to SLIST
> 
>  Use SLIST from sys/queue.h instead of homebrew linked list for the exportlist.
> 
>  Reviewed by:    bapt, rmacklem
>  MFC after:    1 week
>  Sponsored by:    Gandi.net
>  Differential Revision:    https://reviews.freebsd.org/D12502
> 
> Modified:
>  head/usr.sbin/mountd/mountd.c

...

> -            ep2 = exphead;
> -            epp = &exphead;
> +            SLIST_INSERT_HEAD(&exphead, ep, entries);
> 
> -            /*
> -             * Insert in the list in alphabetical order.
> -             */
> -            while (ep2 && strcmp(ep2->ex_fsdir, ep->ex_fsdir) < 0) {
> -                epp = &ep2->ex_next;
> -                ep2 = ep2->ex_next;
> -            }
> -            if (ep2)
> -                ep->ex_next = ep2;
> -            *epp = ep;
>            ep->ex_flag |= EX_LINKED;

    The new code isnft functionally equivalent to the old code: the mount list is no longer sorted on insert. Is that intentional?
Thanks,
-Ngie


Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?C3FC78EB-1445-4AB4-845B-1E5491C77241>