From 8e879f0211fec389f99ebcb97c2faec04c759c0a Mon Sep 17 00:00:00 2001 From: jglick Date: Fri, 6 Apr 2007 22:53:28 +0000 Subject: [PATCH] Working around a bug in CVS affecting incremental builds with local repositories. git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@2900 71c3de6d-444a-0410-be80-ed276b4c234a --- core/src/main/java/hudson/scm/CVSSCM.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/core/src/main/java/hudson/scm/CVSSCM.java b/core/src/main/java/hudson/scm/CVSSCM.java index fca07ecd94..92aa6e648c 100644 --- a/core/src/main/java/hudson/scm/CVSSCM.java +++ b/core/src/main/java/hudson/scm/CVSSCM.java @@ -642,7 +642,15 @@ public class CVSSCM extends AbstractCVSFamilySCM implements Serializable { task.setDir(ws); if(cvspassFile.length()!=0) task.setPassfile(new File(cvspassFile)); - task.setCvsRoot(cvsroot); + if (canUseUpdate && cvsroot.startsWith("/")) { + // cvs log of built source trees unreliable in local access method: + // https://savannah.nongnu.org/bugs/index.php?15223 + task.setCvsRoot(":fork:" + cvsroot); + } else if (canUseUpdate && cvsroot.startsWith(":local:")) { + task.setCvsRoot(":fork:" + cvsroot.substring(7)); + } else { + task.setCvsRoot(cvsroot); + } task.setCvsRsh(cvsRsh); task.setFailOnError(true); task.setDeststream(new BufferedOutputStream(out));