From 2f04b789ec95b3b9abbcca93b537998e064592a4 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Fri, 6 Aug 2010 09:39:01 -0400 Subject: [PATCH] When removing/resetting the timestamp file ignore the tty ticket contents. --HG-- branch : 1.7 --- check.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/check.c b/check.c index 942da76dd..96af763b1 100644 --- a/check.c +++ b/check.c @@ -561,9 +561,12 @@ timestamp_status(timestampdir, timestampfile, user, flags) /* * Check for stored tty info. If the file is zero-sized * it is an old-style timestamp with no tty info in it. + * If removing, we don't care about the contents. * The actual mtime check is done later. */ - if (sb.st_size != 0) { + if (ISSET(flags, TS_REMOVE)) { + status = TS_OLD; + } else if (sb.st_size != 0) { struct tty_info info; int fd = open(timestampfile, O_RDONLY, 0644); if (fd != -1) { -- 2.50.1