Strange character in path can cause you troubles

There are some characters that you shouldn't use in your path. These characters can cause you troubles. I don't recommend to use "&" in path (e.g. "mat & pat").

There was one report from a user of mobility pack. S/he couldn't install any new platform. The root of this problem was that the userdir was in directory "/aaa/bbb & ccc/.netbeans".
Mobility pack copies the bundled WTK2.2 to the userdir and creates platform descriptor for the WTK. The path to platform is stored in xml file and the xml parser expected an entity after the "&". And exception appears :(
org.xml.sax.SAXParseException: The entity name must immediately follow the '&' in the entity reference.
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236)
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:215)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:386)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:31

Solution is easy. Use command line switch "--userdir [path_to_directory]" where path_to_directory doesn't contain "&".

There is another report with similar symptoms. Javadoc in path containing "&" doesn't work as well.

There may be a different characters that can cause a different problem. It is always safe to don't use these "strange" characters in path. Even if NetBeans will treat them in proper way the other tools needn't. E.g. NetBeans Mobility Pack works fine when your userdir contains multibyte characters but the WTK doesn't. It's noticed in Release Notes... I don't expect that anybody reads them ;)
Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
About

This is the main channel to share news, tips and other stuff related to my work. Sometimes you can find even personal stuff. Enjoy your reading...

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today
news
Blogroll

No bookmarks in folder

OldNews
MyTrash
NavBar
NetBeans
LinksToBeExpanded