=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/cvs/rcs.c,v retrieving revision 1.52 retrieving revision 1.53 diff -c -r1.52 -r1.53 *** src/usr.bin/cvs/rcs.c 2005/05/25 08:00:03 1.52 --- src/usr.bin/cvs/rcs.c 2005/05/25 21:32:31 1.53 *************** *** 1,4 **** ! /* $OpenBSD: rcs.c,v 1.52 2005/05/25 08:00:03 jfb Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. --- 1,4 ---- ! /* $OpenBSD: rcs.c,v 1.53 2005/05/25 21:32:31 jfb Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. *************** *** 1282,1292 **** /* * rcs_rev_add() * ! * Add a revision to the RCS file . * Returns 0 on success, or -1 on failure. */ int ! rcs_rev_add(RCSFILE *rf, RCSNUM *rev, const char *msg) { time_t now; struct passwd *pw; --- 1282,1297 ---- /* * rcs_rev_add() * ! * Add a revision to the RCS file . The new revision's number can be ! * specified in (which can also be RCS_HEAD_REV, in which case the ! * new revision will have a number equal to the previous head revision plus ! * one). The argument specifies the log message for that revision, and ! * specifies the revision's date (a value of -1 is ! * equivalent to using the current time). * Returns 0 on success, or -1 on failure. */ int ! rcs_rev_add(RCSFILE *rf, RCSNUM *rev, const char *msg, time_t date) { time_t now; struct passwd *pw; *************** *** 1334,1340 **** return (-1); } ! time(&now); gmtime_r(&now, &(rdp->rd_date)); TAILQ_INSERT_HEAD(&(rf->rf_delta), rdp, rd_list); --- 1339,1348 ---- return (-1); } ! if (date != (time_t)(-1)) ! now = date; ! else ! time(&now); gmtime_r(&now, &(rdp->rd_date)); TAILQ_INSERT_HEAD(&(rf->rf_delta), rdp, rd_list);