diff options
author | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-03-06 13:23:00 +0000 |
---|---|---|
committer | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-03-06 13:23:00 +0000 |
commit | 2fbc05d62fcb5f36fc731fc22ce1faf531c7d568 (patch) | |
tree | 9c3119a93aad9140eb2ceb4615c29dd031f3a49b /usr.bin/rcs/rcsmerge.c | |
parent | 6457be566dedd330ad31b8ca0dbb339f7af3c4d2 (diff) |
adapt informative message if we are sending output to stdout.
Diffstat (limited to 'usr.bin/rcs/rcsmerge.c')
-rw-r--r-- | usr.bin/rcs/rcsmerge.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/usr.bin/rcs/rcsmerge.c b/usr.bin/rcs/rcsmerge.c index 980bd55f7b2..e1275614814 100644 --- a/usr.bin/rcs/rcsmerge.c +++ b/usr.bin/rcs/rcsmerge.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rcsmerge.c,v 1.14 2006/03/06 08:46:55 xsa Exp $ */ +/* $OpenBSD: rcsmerge.c,v 1.15 2006/03/06 13:22:59 xsa Exp $ */ /* * Copyright (c) 2005, 2006 Xavier Santolaria <xsa@openbsd.org> * All rights reserved. @@ -35,7 +35,7 @@ int rcsmerge_main(int argc, char **argv) { int i, ch; - char *fcont, fpath[MAXPATHLEN]; + char *fcont, fpath[MAXPATHLEN], r1[16], r2[16]; RCSFILE *file; RCSNUM *baserev, *rev2, *frev; BUF *bp; @@ -121,6 +121,12 @@ rcsmerge_main(int argc, char **argv) continue; } + rcsnum_tostr(baserev, r1, sizeof(r1)); + rcsnum_tostr(frev, r2, sizeof(r2)); + + printf("Merging differences between %s and %s into %s%s\n", + r1, r2, argv[i], (pipeout == 1) ? "; result to stdout":""); + if ((bp = cvs_diff3(file, argv[i], baserev, frev)) == NULL) { cvs_log(LP_ERR, "failed to merge"); rcs_close(file); |