=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ruptime/Attic/ruptime.c,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- src/usr.bin/ruptime/Attic/ruptime.c 1997/06/20 09:59:27 1.4 +++ src/usr.bin/ruptime/Attic/ruptime.c 1997/07/06 02:28:55 1.5 @@ -1,4 +1,4 @@ -/* $OpenBSD: ruptime.c,v 1.4 1997/06/20 09:59:27 deraadt Exp $ */ +/* $OpenBSD: ruptime.c,v 1.5 1997/07/06 02:28:55 millert Exp $ */ /* * Copyright (c) 1983 The Regents of the University of California. @@ -41,7 +41,7 @@ #ifndef lint /*static char sccsid[] = "from: @(#)ruptime.c 5.8 (Berkeley) 7/21/90";*/ -static char rcsid[] = "$OpenBSD: ruptime.c,v 1.4 1997/06/20 09:59:27 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: ruptime.c,v 1.5 1997/07/06 02:28:55 millert Exp $"; #endif /* not lint */ #include @@ -189,18 +189,18 @@ static char resbuf[32]; int days, hours, minutes; - if (tval < 0 || tval > 365*24*60*60) { - (void)sprintf(resbuf, " %s ??:??", updown); + if (tval < 0 || tval > 999*24*60*60) { + (void)sprintf(resbuf, "%s ??:??", updown); return(resbuf); } minutes = (tval + 59) / 60; /* round to minutes */ hours = minutes / 60; minutes %= 60; days = hours / 24; hours %= 24; if (days) - (void)sprintf(resbuf, "%s %2d+%02d:%02d", + (void)sprintf(resbuf, "%s %3d+%02d:%02d", updown, days, hours, minutes); else - (void)sprintf(resbuf, "%s %2d:%02d", + (void)sprintf(resbuf, "%s %2d:%02d", updown, hours, minutes); return(resbuf); }