Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with Locale deserialization #5

Open
GoogleCodeExporter opened this issue Oct 23, 2015 · 0 comments
Open

Problem with Locale deserialization #5

GoogleCodeExporter opened this issue Oct 23, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. We are using hessdroid library for android client.
2. When the server sends an object of java.util.Locale then hessdroid
library throws the following exception:

com.caucho.hessian.io.HessianFieldException: 
com.<custom data type having locale as field>.locale:
com.caucho.hessian.io.LocaleHandle 
(com.caucho.hessian.io.LocaleHandle@437aaa60) cannot be assigned to
'java.util.Locale'

3. While debugging we found inside method 
com.caucho.hessian.io.JavaDeserializer.ObjectFieldDeserializer.deserialize()
that the statement
  field.set(obj, value);
throws the exception while setting the Locale field type.

4. We tried to fix this. We changed the access modifier of
com.caucho.hessian.io.LocaleHandle.readResolve() method from private to
public. This resolved the problem.

What is the expected output? What do you see instead?
The Locale object should be properly resolved.

What version of the product are you using? On what operating system?
Checked out source code on April 8, 2010. We are working on Windows XP SP3.

Please provide any additional information below.
Could you please confirm if the fix is appropriate and when can we expect
the new library release?

Thanks
Raju Mahore

Original issue reported on code.google.com by rajumahore on 21 Apr 2010 at 12:40

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant