(otp_get_internal): Save lock_time in returned struct.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@1929 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1997-06-27 13:32:28 +00:00
parent ac09688ffd
commit 4ee84f9b86

View File

@@ -121,9 +121,10 @@ otp_get_internal (void *v, OtpContext *ctx, int lockp)
} }
p = dat.dptr; p = dat.dptr;
memcpy (&then, p, sizeof(then));
ctx->lock_time = then;
if (lockp) { if (lockp) {
time(&now); time(&now);
memcpy (&then, p, sizeof(then));
if (then && now - then < OTP_USER_TIMEOUT) { if (then && now - then < OTP_USER_TIMEOUT) {
ctx->err = "Entry locked"; ctx->err = "Entry locked";
return -1; return -1;