Attached is a patch to fix a bug with the XML Schema SourceGenerator.
It was not escaping '\"' characters in strings printed when creating
the java source files.

Regards,

Glenn

----------------------------------------------------------------------
Glenn Nielsen             [EMAIL PROTECTED] | /* Spelin donut madder    |
MOREnet System Programming               |  * if iz ina coment.      |
Missouri Research and Education Network  |  */                       |
----------------------------------------------------------------------
*** castor/src/main/org/exolab/castor/builder/DescriptorSourceFactory.java      Wed 
Oct 31 19:55:23 2001
--- castor-patched/src/main/org/exolab/castor/builder/DescriptorSourceFactory.java     
 Fri Nov  9 19:09:15 2001
***************
*** 1606,1612 ****
          if (str == null) return str;
  
          //-- make sure we have characters to escape
!         if (str.indexOf('\\') < 0) return str;
  
          StringBuffer sb = new StringBuffer();
          char[] chars = str.toCharArray();
--- 1606,1612 ----
          if (str == null) return str;
  
          //-- make sure we have characters to escape
!         if (str.indexOf('\\') < 0 && str.indexOf('\"') < 0) return str;
  
          StringBuffer sb = new StringBuffer();
          char[] chars = str.toCharArray();
***************
*** 1614,1619 ****
--- 1614,1620 ----
          for (int i = 0; i < chars.length; i++) {
              char ch = chars[i];
              if (ch == '\\') sb.append(ch);
+             if (ch == '\"') sb.append('\\');
              sb.append(ch);
          }
          return sb.toString();

Reply via email to