axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kamlesh kumar <>
Subject xsd deserialization for integer types broken
Date Mon, 18 Sep 2006 20:30:05 GMT
The xsd deserialization for integer types is awfully

For instance, calling the getElementAsInt() API for
the XML fragment


I would have expected it to either return 30 or
ideally throw an exception. Instead, I get a value of
300 :( 

Similarly, calling 

"<foo>30 </foo>" returns a value of 300 !

I think the following change might have introduced
this bug.

Further, why aren't we validating against the maximum
and minimum value for each type ?

For instance, getElementAsShort() for the XML fragment

"<foo1>32768</foo1>" returns -1. I would have expected
AxisC++ to throw an exception saying it exceeds the
max value of short instead of silently returning wrong

I am surprised why this bug hasn't been seen till now.

Regardless, I think it should be top priority to fix
this issue. 


Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message