summaryrefslogtreecommitdiffstats
path: root/contrib/cvs/src/vers_ts.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/cvs/src/vers_ts.c')
-rw-r--r--contrib/cvs/src/vers_ts.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/contrib/cvs/src/vers_ts.c b/contrib/cvs/src/vers_ts.c
index e1ba32d..8d55284 100644
--- a/contrib/cvs/src/vers_ts.c
+++ b/contrib/cvs/src/vers_ts.c
@@ -87,22 +87,17 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time)
vers_ts->vn_user = xstrdup (entdata->version);
vers_ts->ts_rcs = xstrdup (entdata->timestamp);
vers_ts->ts_conflict = xstrdup (entdata->conflict);
- if (!tag)
+ if (!(tag || date) && !(sdtp && sdtp->aflag))
{
- if (!(sdtp && sdtp->aflag))
- vers_ts->tag = xstrdup (entdata->tag);
- }
- if (!date)
- {
- if (!(sdtp && sdtp->aflag))
- vers_ts->date = xstrdup (entdata->date);
+ vers_ts->tag = xstrdup (entdata->tag);
+ vers_ts->date = xstrdup (entdata->date);
}
vers_ts->entdata = entdata;
}
/* Even if we don't have an "entries line" as such
(vers_ts->entdata), we want to pick up options which could
have been from a Kopt protocol request. */
- if (!options || (options && *options == '\0'))
+ if (!options || *options == '\0')
{
if (!(sdtp && sdtp->aflag))
vers_ts->options = xstrdup (entdata->options);
@@ -126,6 +121,8 @@ Version_TS (finfo, options, tag, date, force_tag_match, set_time)
char *rcsexpand = RCS_getexpand (finfo->rcs);
if (rcsexpand != NULL)
{
+ if (vers_ts->options != NULL)
+ free (vers_ts->options);
vers_ts->options = xmalloc (strlen (rcsexpand) + 3);
strcpy (vers_ts->options, "-k");
strcat (vers_ts->options, rcsexpand);
OpenPOWER on IntegriCloud