diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-07-13 20:41:56 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2010-07-13 20:41:56 +0000 |
commit | debab3bb5cccf247c59058e7a8b5442847bae173 (patch) | |
tree | bb34dd457b45c93708cf3c79e6bf461682c461eb | |
parent | ecccd1851efb3e03472cfa4c5c40868ab77019a4 (diff) |
PR 6423 fix for cvs too, requested by xsa@.
-rw-r--r-- | usr.bin/cvs/rcs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/cvs/rcs.c b/usr.bin/cvs/rcs.c index b524ad82188..1067620f10b 100644 --- a/usr.bin/cvs/rcs.c +++ b/usr.bin/cvs/rcs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rcs.c,v 1.293 2010/07/09 20:07:05 naddy Exp $ */ +/* $OpenBSD: rcs.c,v 1.294 2010/07/13 20:41:55 nicm Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org> * All rights reserved. @@ -492,7 +492,7 @@ rcs_write(RCSFILE *rfp) if (rdp->rd_log != NULL) { len = strlen(rdp->rd_log); rcs_strprint((const u_char *)rdp->rd_log, len, fp); - if (rdp->rd_log[len-1] != '\n') + if (len == 0 || rdp->rd_log[len-1] != '\n') fputc('\n', fp); } fputs("@\ntext\n@", fp); |