summaryrefslogtreecommitdiff
path: root/source4/torture/rpc
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2012-12-11 13:34:49 +0100
committerStefan Metzmacher <metze@samba.org>2012-12-11 14:00:00 +0100
commit498f98f126de6da5aff7f054a85270f315c7a400 (patch)
treee22cb6b085d5d9f4400e18a564b0cb4f1af52033 /source4/torture/rpc
parent1a4adcfcb31a06fe3eae4e78a502cbfaa092587e (diff)
downloadsamba-498f98f126de6da5aff7f054a85270f315c7a400.tar.gz
samba-498f98f126de6da5aff7f054a85270f315c7a400.tar.bz2
samba-498f98f126de6da5aff7f054a85270f315c7a400.zip
s4:torture:rpc:samr: fix password age calculation in test_ChangePasswordUser3()
The min_password_age field is the negative of the age. Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Michael Adam <obnox@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source4/torture/rpc')
-rw-r--r--source4/torture/rpc/samr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c
index 01f4c0fdc2..f17f0d746c 100644
--- a/source4/torture/rpc/samr.c
+++ b/source4/torture/rpc/samr.c
@@ -2490,8 +2490,8 @@ bool test_ChangePasswordUser3(struct dcerpc_pipe *p, struct torture_context *tct
Guenther */
- if ((dominfo->min_password_age > 0) && !null_nttime(last_password_change) &&
- (last_password_change + dominfo->min_password_age > t)) {
+ if ((dominfo->min_password_age < 0) && !null_nttime(last_password_change) &&
+ (last_password_change - dominfo->min_password_age > t)) {
if (reject->extendedFailureReason != SAM_PWD_CHANGE_NO_ERROR) {
torture_warning(tctx, "expected SAM_PWD_CHANGE_NO_ERROR (%d), got %d\n",