Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/bsd/cron/dist remove the +1 second. Otherwise jobs ...
details: https://anonhg.NetBSD.org/src/rev/ce003103b954
branches: trunk
changeset: 754651:ce003103b954
user: christos <christos%NetBSD.org@localhost>
date: Fri May 07 17:12:00 2010 +0000
description:
remove the +1 second. Otherwise jobs that are supposed to run at 10:00:00,
run at 10:00:01 which is tolerable because cron has a 1 minute granularity,
but confusing. This restores the old behavior with the new timing logic.
diffstat:
external/bsd/cron/dist/cron.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r b37d89cee804 -r ce003103b954 external/bsd/cron/dist/cron.c
--- a/external/bsd/cron/dist/cron.c Fri May 07 17:06:32 2010 +0000
+++ b/external/bsd/cron/dist/cron.c Fri May 07 17:12:00 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cron.c,v 1.4 2010/05/06 22:38:14 christos Exp $ */
+/* $NetBSD: cron.c,v 1.5 2010/05/07 17:12:00 christos Exp $ */
/* Copyright 1988,1990,1993,1994 by Paul Vixie
* All rights reserved
@@ -25,7 +25,7 @@
#if 0
static char rcsid[] = "Id: cron.c,v 1.12 2004/01/23 18:56:42 vixie Exp";
#else
-__RCSID("$NetBSD: cron.c,v 1.4 2010/05/06 22:38:14 christos Exp $");
+__RCSID("$NetBSD: cron.c,v 1.5 2010/05/07 17:12:00 christos Exp $");
#endif
#endif
@@ -362,7 +362,7 @@
int seconds_to_wait;
t1 = time(NULL) + GMToff;
- seconds_to_wait = (int)(target * SECONDS_PER_MINUTE - t1) + 1;
+ seconds_to_wait = (int)(target * SECONDS_PER_MINUTE - t1);
Debug(DSCH, ("[%ld] Target time=%lld, sec-to-wait=%d\n",
(long)getpid(), (long long)target*SECONDS_PER_MINUTE,
seconds_to_wait));
Home |
Main Index |
Thread Index |
Old Index