I did a client in java that send one string with blanks, just like "Hello world", but the server HelloServer, receives the string like this: "Hello, Hello world."
How do i receive the correct value with blank?
I'm using the XmlRpc lib from apache to Java, and the c++ code is the HelloServer with xmlrpc++0.7 and my VS6 is patched.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I had the same problem going from Apache Java to C++ and tracked the problem down to the XmlRpcUtil::xmlDecode method. The implementation is fairly primitive in that it only looks for five pre-defined URL escapes (<, >, &, ', ") and doesn't look for escaped ASCII characters in the format  .
Since the space character was the only character getting escaped that I was interested in, I decided to just add another hardcoded escape to their method. If I hadn't been pressed by my schedule, I would have written a patch that properly looks for &#..; and converts to the correct ASCII char. I may get around to it in my project's next release.
A simple fix:
Look for the declaration of the constants rawEntity, xmlEntity, and xmlEntLen. Add the appropriate elements to each for the space char. For example, add:
' ' to rawEntity
"#32;" to xmlEntity
4 to xmlEntLen
This should take of the space escape.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I did a client in java that send one string with blanks, just like "Hello world", but the server HelloServer, receives the string like this: "Hello, Hello world."
How do i receive the correct value with blank?
I'm using the XmlRpc lib from apache to Java, and the c++ code is the HelloServer with xmlrpc++0.7 and my VS6 is patched.
I had the same problem going from Apache Java to C++ and tracked the problem down to the XmlRpcUtil::xmlDecode method. The implementation is fairly primitive in that it only looks for five pre-defined URL escapes (<, >, &, ', ") and doesn't look for escaped ASCII characters in the format  .
Since the space character was the only character getting escaped that I was interested in, I decided to just add another hardcoded escape to their method. If I hadn't been pressed by my schedule, I would have written a patch that properly looks for &#..; and converts to the correct ASCII char. I may get around to it in my project's next release.
A simple fix:
Look for the declaration of the constants rawEntity, xmlEntity, and xmlEntLen. Add the appropriate elements to each for the space char. For example, add:
' ' to rawEntity
"#32;" to xmlEntity
4 to xmlEntLen
This should take of the space escape.