summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Sojka <sojkam1@fel.cvut.cz>2008-03-30 03:24:19 +0200
committerYann Dirson <ydirson@altern.org>2008-03-31 16:09:13 +0200
commit42642161f6beb70c3197c4f8b46cccafa58bd6e4 (patch)
tree78f6526663eb6c9c2af1a6d7a708db8f3048c54b
parentd21458c0fe3e64313b23b406a5df64565d210034 (diff)
downloadcvsps-to-check.tar.gz
Do not ignore subdirectories on CVSNT serversto-check
With my CVSNT server (1.11.1.3 (Build 57j), CVSPS ignored files in subdirectories. The reason was that in output of cvs rlog, files were separated from repository path by / whereas directories by \: RCS file: d:\cvs\laser/BUILD.INC,v ... RCS file: d:\cvs\laser\DLG/DABOUT.DLG,v Now, if filename does not start with repository path, another comparison is done to check whether the only difference is the last slash or backslash. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
-rw-r--r--cvsps.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/cvsps.c b/cvsps.c
index 1fa41d2..60e8504 100644
--- a/cvsps.c
+++ b/cvsps.c
@@ -1145,6 +1145,14 @@ static CvsFile * parse_rcs_file(const char * buff)
}
}
+ /* Windows CVS server may use two path separators: / for files
+ * and \ for subdirectories. */
+ if (strncmp(fn, strip_path, strip_path_len-1) == 0 &&
+ (fn[strip_path_len-1] == '\\' ||
+ fn[strip_path_len-1] == '/')) {
+ goto ok;
+ }
+
/* FIXME: a subdirectory may have a different Repository path
* than it's parent. we'll fail the above test since strip_path
* is global for the entire checked out tree (recursively).