=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/cvs/status.c,v retrieving revision 1.39 retrieving revision 1.40 diff -u -r1.39 -r1.40 --- src/usr.bin/cvs/status.c 2005/07/10 13:58:19 1.39 +++ src/usr.bin/cvs/status.c 2005/07/14 06:54:59 1.40 @@ -1,4 +1,4 @@ -/* $OpenBSD: status.c,v 1.39 2005/07/10 13:58:19 xsa Exp $ */ +/* $OpenBSD: status.c,v 1.40 2005/07/14 06:54:59 xsa Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. @@ -180,9 +180,7 @@ size_t n; char buf[MAXNAMLEN], fpath[MAXPATHLEN], rcspath[MAXPATHLEN]; char numbuf[64], timebuf[32]; - char *repo; RCSFILE *rf; - struct cvsroot *root; if (cf->cf_type == DT_DIR) { if (verbosity > 1) @@ -190,18 +188,10 @@ return (0); } - root = CVS_DIR_ROOT(cf); - repo = CVS_DIR_REPO(cf); - cvs_file_getpath(cf, fpath, sizeof(fpath)); - len = snprintf(rcspath, sizeof(rcspath), "%s/%s/%s%s", - root->cr_dir, repo, CVS_FILE_NAME(cf), RCS_FILE_EXT); - if (len == -1 || len >= (int)sizeof(rcspath)) { - errno = ENAMETOOLONG; - cvs_log(LP_ERRNO, "%s", rcspath); + if (cvs_rcs_getpath(cf, rcspath, sizeof(rcspath)) == NULL) return (CVS_EX_DATA); - } if (cf->cf_cvstat != CVS_FST_UNKNOWN && cf->cf_cvstat != CVS_FST_ADDED) {