This fixes an issue with running js2doc.test on Windows. Platform contributors who run 'ant test', and window-builder, are presumably affected. Risk is very low.

jim

Begin forwarded message:

From: [EMAIL PROTECTED]
Date: March 28, 2007 2:17:06 PM PDT
To: [email protected]
Subject: [Laszlo-checkins] r4538 - openlaszlo/branches/legals/WEB- INF/lps/server/src/org/openlaszlo/js2doc
Reply-To: [email protected]

Author: jgrandy
Date: 2007-03-28 14:17:03 -0700 (Wed, 28 Mar 2007)
New Revision: 4538

Modified:
openlaszlo/branches/legals/WEB-INF/lps/server/src/org/openlaszlo/ js2doc/JS2Doc.java
Log:
Change 20070327-jgrandyw-k by [EMAIL PROTECTED] on 2007-03-27 11:40:52 PDT
    in /Users/jgrandyw/dev/svn/openlaszlo/branches/legals
    for http://svn.openlaszlo.org/openlaszlo/branches/legals

Summary: Fix Windows-only failure with js2doc.test

Bugs Fixed: LPP-3782

Technical Reviewer: hqm
QA Reviewer:
Doc Reviewer:


Files:
M      WEB-INF/lps/server/src/org/openlaszlo/js2doc/JS2Doc.java


Modified: openlaszlo/branches/legals/WEB-INF/lps/server/src/org/ openlaszlo/js2doc/JS2Doc.java
===================================================================
--- openlaszlo/branches/legals/WEB-INF/lps/server/src/org/ openlaszlo/js2doc/JS2Doc.java 2007-03-28 20:38:30 UTC (rev 4537) +++ openlaszlo/branches/legals/WEB-INF/lps/server/src/org/ openlaszlo/js2doc/JS2Doc.java 2007-03-28 21:17:03 UTC (rev 4538)
@@ -121,8 +121,13 @@
                         this.processComment(unitNode, parsedComment);
                 }

- String relativePath = this.relativeBase + java.io.File.separator + unitPath;
-                if (relativePath.charAt(0) == File.separatorChar)
+ // no need to use java.io.File.separatorChar here, since the separator
+                // will appear unix-style (as '/') in the source code
+ String relativePath = this.relativeBase + '/' + unitPath; + // relativeBase may (erroneously) start with a '/', or may be the empty + // string, so cover both cases here to ensure we have a truly relative
+                // path.
+                if (relativePath.charAt(0) == '/')
                     relativePath = relativePath.substring(1);

                 unitNode.setAttribute("path", relativePath);


_______________________________________________
Laszlo-checkins mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-checkins

Reply via email to