[PATCH] DFS referral shuffling
David Disseldorp
ddiss at suse.de
Thu Feb 26 06:44:10 MST 2015
Thanks for the patch Robin. I have a few minor comments inline...
On Sun, 15 Feb 2015 17:34:03 +0000, Robin McCorkell wrote:
> From aea01b7562a73e53d739e1c8bb17fd7c105ec520 Mon Sep 17 00:00:00 2001
> From: Robin McCorkell <rmccorkell at karoshi.org.uk>
> Date: Thu, 5 Feb 2015 14:06:15 +0000
> Subject: [PATCH 1/2] MSDFS referral shuffling
Please add a description and signed-off-by tag to your change, according
to https://www.samba.org/samba/devel/copyright-policy.html .
> ---
> docs-xml/smbdotconf/vfs/msdfsshufflereferrals.xml | 16 ++++++++++++++
> lib/param/param_table.c | 9 ++++++++
> source3/param/loadparm.c | 1 +
> source3/smbd/msdfs.c | 27 ++++++++++++++++++++---
> 4 files changed, 50 insertions(+), 3 deletions(-)
> create mode 100644 docs-xml/smbdotconf/vfs/msdfsshufflereferrals.xml
>
> diff --git a/docs-xml/smbdotconf/vfs/msdfsshufflereferrals.xml b/docs-xml/smbdotconf/vfs/msdfsshufflereferrals.xml
> new file mode 100644
> index 0000000..771982f
> --- /dev/null
> +++ b/docs-xml/smbdotconf/vfs/msdfsshufflereferrals.xml
> @@ -0,0 +1,16 @@
> +<samba:parameter name="msdfs shuffle referrals"
> + context="S"
> + type="boolean"
> + xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
> +<description>
> + <para>If set to <constant>yes</constant>, Samba will shuffle
> + Dfs referrals for a given Dfs link if multiple are available,
> + allowing for load balancing across clients. For more information
> + on setting up a Dfs tree on Samba, refer to the MSDFS chapter in
Looks like there's some white-space damage here.
...
> +static void shuffle_referrals(const char **list, int count) {
Opening bracket should be on a new line for functions.
FWIW, this Fisher-Yates shuffle isn't DFS referral specific, so should
probably be renamed as such.
The rest of this change looks reasonable. I've attached an extra commit
that adds some test coverage for this change.
Cheers, David
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-selftest-shuffle-msdfs-share-DFS-referral-responses.patch
Type: text/x-patch
Size: 1226 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150226/028be5db/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150226/028be5db/attachment.pgp>
More information about the samba-technical
mailing list