scheu       02/04/22 11:02:09

  Modified:    java/src/org/apache/axis/encoding/ser DateDeserializer.java
  Log:
  Bug fix for:
  http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8106
  
  Stretched existing synchronized block to include reference to the static zulu.
  
  Revision  Changes    Path
  1.3       +12 -12    
xml-axis/java/src/org/apache/axis/encoding/ser/DateDeserializer.java
  
  Index: DateDeserializer.java
  ===================================================================
  RCS file: 
/home/cvs/xml-axis/java/src/org/apache/axis/encoding/ser/DateDeserializer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DateDeserializer.java     31 Mar 2002 23:09:33 -0000      1.2
  +++ DateDeserializer.java     22 Apr 2002 18:02:09 -0000      1.3
  @@ -119,23 +119,23 @@
               
           }
           
  -        // convert what we have validated so far
  -        try {
  -            result = zulu.parse(source == null ? null :
  -                                (source.substring(0,10)) );
  -        } catch (Exception e) {
  -            throw new NumberFormatException(e.toString());
  -        }
  -
  -        // support dates before the Christian era
  -        if (bc) {
  -            synchronized (calendar) {
  +        synchronized (calendar) {
  +            // convert what we have validated so far
  +            try {
  +                result = zulu.parse(source == null ? null :
  +                                    (source.substring(0,10)) );
  +            } catch (Exception e) {
  +                throw new NumberFormatException(e.toString());
  +            }
  +            
  +            // support dates before the Christian era
  +            if (bc) {
                   calendar.setTime(result);
                   calendar.set(Calendar.ERA, GregorianCalendar.BC);
                   result = calendar.getTime();
               }
           }
  -        
  +
           return result;
       }
   }
  
  
  


Reply via email to