]> git.decadent.org.uk Git - nfs-utils.git/commit - support/export/client.c
libexport.a: Factor FQDN checking out of check_client()
authorChuck Lever <chuck.lever@oracle.com>
Thu, 8 Apr 2010 14:50:41 +0000 (10:50 -0400)
committerSteve Dickson <steved@redhat.com>
Thu, 8 Apr 2010 15:16:17 +0000 (11:16 -0400)
commit6abde64e6a605443dfc283ffb2642cb853f8b5b0
tree5ede69d64b4dc83b241472a754222ce6a5f813e4
parente8a54a3d5e32c9de009f84d1ef3f26d2dffbf226
libexport.a: Factor FQDN checking out of check_client()

Clean up:  Factor the MCL_FQDN case out of check_client() and
client_checkaddr().  This will make it easier to add IPv6 support
eventually.

The logic in the new helper function will get a little more tangled
once IPv6 support is introduced.  Each slot in the clp address list
eventually may contain an address from either address family.

Note that the switch statement in client_checkaddr() is redundant,
since clp->cl_mtype is loop invariant.  This change makes FQDN client
checking more computationally efficient, at the cost of a few extra
lines of code.

This commit should not change code behavior in any way.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
support/export/client.c