diff options
Diffstat (limited to 'contrib/cvs/src/create_adm.c')
-rw-r--r-- | contrib/cvs/src/create_adm.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/contrib/cvs/src/create_adm.c b/contrib/cvs/src/create_adm.c index 878b058..1ab0f28 100644 --- a/contrib/cvs/src/create_adm.c +++ b/contrib/cvs/src/create_adm.c @@ -84,7 +84,7 @@ Create_Admin (dir, update_dir, repository, tag, date, nonbranch, warn, /* record the current cvs root for later use */ - Create_Root (dir, CVSroot_original); + Create_Root (dir, current_parsed_root->original); if (dir != NULL) (void) sprintf (tmp, "%s/%s", dir, CVSADM_REP); else @@ -106,7 +106,7 @@ Create_Admin (dir, update_dir, repository, tag, date, nonbranch, warn, spend the time making sure all of the code can handle it if we don't do it. */ - if (strcmp (reposcopy, CVSroot_directory) == 0) + if (strcmp (reposcopy, current_parsed_root->directory) == 0) { reposcopy = xrealloc (reposcopy, strlen (reposcopy) + 3); strcat (reposcopy, "/."); @@ -119,14 +119,13 @@ Create_Admin (dir, update_dir, repository, tag, date, nonbranch, warn, * If the Repository file is to hold a relative path, try to strip off * the leading CVSroot argument. */ - if (CVSroot_directory != NULL) { - char *path = xmalloc (strlen (CVSroot_directory) + 10); + char *path = xmalloc (strlen (current_parsed_root->directory) + 2); - (void) sprintf (path, "%s/", CVSroot_directory); - if (strncmp (cp, path, strlen (path)) == 0) - cp += strlen (path); - free (path); + (void) sprintf (path, "%s/", current_parsed_root->directory); + if (strncmp (cp, path, strlen (path)) == 0) + cp += strlen (path); + free (path); } #endif |