X-Git-Url: http://git.samba.org/idra/samba.git/?p=idra%2Fsamba.git;a=blobdiff_plain;f=source3%2Fpassdb%2Fpdb_get_set.c;h=d0d7317e68d44acbf678d7830c66fe2d1912321c;hp=4ff13808c368e6bdd430abe6085440abe4d5f649;hb=add8505fde9d178b3a0dbb71a207485cdb8fc161;hpb=c5e41a21dd2dad9b43b40b38f75cea0da67c2cce diff --git a/source3/passdb/pdb_get_set.c b/source3/passdb/pdb_get_set.c index 4ff13808c36..d0d7317e68d 100644 --- a/source3/passdb/pdb_get_set.c +++ b/source3/passdb/pdb_get_set.c @@ -1088,3 +1088,26 @@ uint32_t pdb_build_fields_present(struct samu *sampass) /* value set to all for testing */ return 0x00ffffff; } + +/********************************************************************** + Helper function to determine for update_sam_account whether + we need LDAP modification. +*********************************************************************/ + +bool pdb_element_is_changed(const struct samu *sampass, + enum pdb_elements element) +{ + return IS_SAM_CHANGED(sampass, element); +} + +/********************************************************************** + Helper function to determine for update_sam_account whether + we need LDAP modification. + *********************************************************************/ + +bool pdb_element_is_set_or_changed(const struct samu *sampass, + enum pdb_elements element) +{ + return (IS_SAM_SET(sampass, element) || + IS_SAM_CHANGED(sampass, element)); +}