axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/encoding/ser BeanSerializer.java
Date Fri, 22 Feb 2002 20:04:43 GMT
tomj        02/02/22 12:04:43

  Modified:    java/src/org/apache/axis/encoding/ser BeanSerializer.java
  Log:
  Add defensive code to prevent initializing an attributes object
  in getObjectAttributes() with a null.
  
  Revision  Changes    Path
  1.8       +6 -2      xml-axis/java/src/org/apache/axis/encoding/ser/BeanSerializer.java
  
  Index: BeanSerializer.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/encoding/ser/BeanSerializer.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- BeanSerializer.java	21 Feb 2002 19:25:07 -0000	1.7
  +++ BeanSerializer.java	22 Feb 2002 20:04:43 -0000	1.8
  @@ -417,8 +417,12 @@
           
           if (beanAttributeNames.isEmpty())
               return attributes;
  -        
  -        AttributesImpl attrs = new AttributesImpl(attributes);
  +
  +        AttributesImpl attrs;
  +        if (attributes != null)
  +            attrs = new AttributesImpl(attributes);
  +        else
  +            attrs = new AttributesImpl();
           
           try {
               // Find each property that is an attribute 
  
  
  

Mime
View raw message