summaryrefslogtreecommitdiff
path: root/source3/lib/util_list.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-03-07 23:59:13 +0000
committerJeremy Allison <jra@samba.org>2001-03-07 23:59:13 +0000
commit393bede7db6af546431cd5255e465b7b7b0e7c81 (patch)
tree44a95a722eba6f412e50efc34e2233baa31fe987 /source3/lib/util_list.c
parent2b22019e426c4bb7a5745a326c302a4e19aa5ff2 (diff)
downloadsamba-393bede7db6af546431cd5255e465b7b7b0e7c81.tar.gz
samba-393bede7db6af546431cd5255e465b7b7b0e7c81.tar.bz2
samba-393bede7db6af546431cd5255e465b7b7b0e7c81.zip
Sync up handle creation with 2.2 branch. We can now join AS/U domains and
authenticate against them. Big/little endian issues fixed. Jeremy. (This used to be commit 0e6a34510ed598eaec7fe71a9c91fda528a4675c)
Diffstat (limited to 'source3/lib/util_list.c')
-rw-r--r--source3/lib/util_list.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/source3/lib/util_list.c b/source3/lib/util_list.c
index ea262b5db5..19354c8784 100644
--- a/source3/lib/util_list.c
+++ b/source3/lib/util_list.c
@@ -193,8 +193,6 @@ static void* generic_list_locate (GENERIC_LIST *l, void *search,
*************************************************************/
BOOL copy_policy_hnd (POLICY_HND *dest, const POLICY_HND *src)
{
- int i;
-
/* if we have no destination, return an error */
if (dest == NULL)
return False;
@@ -205,14 +203,11 @@ BOOL copy_policy_hnd (POLICY_HND *dest, const POLICY_HND *src)
{
/* if POLICY_HND internals ever changes,
this will need to be fixed */
- memset (dest->data, 0, POLICY_HND_SIZE);
+ ZERO_STRUCTP(dest);
return True;
}
- /* copy the src handle to the dest */
- for (i=0; i<POLICY_HND_SIZE; i++)
- dest->data[i] = src->data[i];
-
+ *dest = *src;
return True;
}
@@ -240,7 +235,7 @@ BOOL compare_rpc_hnd_node(const RPC_HND_NODE *x,
/* if the POLICY_HND field(s) are ever changed, this
will need to be updated. Probably should be a set of
support function for dealing with POLICY_HND */
- return (memcmp(x->hnd.data, y->hnd.data, POLICY_HND_SIZE) == 0);
+ return (memcmp(&x->hnd, &y->hnd, sizeof(POLICY_HND)) == 0);
}
/***************************************************************