neil-benn / svnrevisionlabeller

Automatically exported from code.google.com/p/svnrevisionlabeller
0 stars 0 forks source link

SVN Urls should be quoted #9

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Configure a Labeller with an SVN Url that contains spaces.
2. Run/Force a build with those settings.
3. GetRevision throws an Xml Error since svn log does not return
complete/well-formed Xml due to the incomplete path.

What is the expected output? What do you see instead?
<url>http://svn.local/svn/space/trunk/this folder contains spaces</url>
Debug output:
[4128:DEBUG] [Project-with-space svn.exe] svn:
'/svn/space/!svn/bc/605/trunk/this' path not found
[4356:DEBUG] [Project-with-space svn.exe] <?xml version="1.0"?>
[4356:DEBUG] [Project-with-space svn.exe] <log>
[Project-with-space:DEBUG] Received XML : <?xml version="1.0"?>
<log>

Error Message:      System.Xml.XmlException: Unexpected end of file has
occurred. The following elements are not closed: log. Line 3, position 1.
at System.Xml.XmlTextReaderImpl.Throw(Exception e) at
System.Xml.XmlTextReaderImpl.ThrowUnclosedElements() at
System.Xml.XmlTextReaderImpl.ParseElementContent() at
System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace) at
System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc) at
System.Xml.XmlDocument.Load(XmlReader reader) at
System.Xml.XmlDocument.LoadXml(String xml) at
ccnet.SvnRevisionLabeller.plugin.SvnRevisionLabeller.GetRevision() at
ccnet.SvnRevisionLabeller.plugin.SvnRevisionLabeller.Generate(IIntegrationResult
resultFromLastBuild) at
ThoughtWorks.CruiseControl.Core.Project.Prebuild(IIntegrationResult result)
at
ThoughtWorks.CruiseControl.Core.IntegrationRunner.Build(IIntegrationResult
result)

What version of the product are you using? On what operating system?
SVN r3

Please provide any additional information below.
Replace the call in GetRevision 
 argBuilder.AppendArgument(Url);
with the following:
 argBuilder.AppendArgument('"' + Url + '"');
(or equivalent)

Original issue reported on code.google.com by j4ck.fr0st@gmail.com on 19 Feb 2009 at 8:45

GoogleCodeExporter commented 8 years ago
I've got a fix lined up, it just needs testing (preferably of the automated 
variety).

Original comment by davidkeaveny on 19 Feb 2009 at 9:36