I'm having the strangest problem, and I'm wondering if anybody else has seen it.
I've been using XmlRpc++ in VS6 just fine. Now I'm trying it in visual studio .net 2003. In XmlRpcServerConnection, when it parses the parameters and puts them in the param XmlRpcValue, I get a range exception. I traced it down to the allocation of a new element when resizing the vector or creating a new vector with 1 element. In the allocate template function/class/method/whatever, in new(), it calls malloc() with _Count * sizeof( _Ty ). Of course _Ty is the template, which is XmlRpcValue. The problem is, in this case, sizeof( _Ty ) returns 12 instead of 16. In a different executable I can create a new XmlRpcValue x, then say x[0] = XmlRpcValue(true); and everything works fine, sizeof(_Ty) returns 16, and everything is happy. But in this context, creating the params XmlRpcValue array, this same exact thing happens every time.
Anybody else have any insight on this?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm having the strangest problem, and I'm wondering if anybody else has seen it.
I've been using XmlRpc++ in VS6 just fine. Now I'm trying it in visual studio .net 2003. In XmlRpcServerConnection, when it parses the parameters and puts them in the param XmlRpcValue, I get a range exception. I traced it down to the allocation of a new element when resizing the vector or creating a new vector with 1 element. In the allocate template function/class/method/whatever, in new(), it calls malloc() with _Count * sizeof( _Ty ). Of course _Ty is the template, which is XmlRpcValue. The problem is, in this case, sizeof( _Ty ) returns 12 instead of 16. In a different executable I can create a new XmlRpcValue x, then say x[0] = XmlRpcValue(true); and everything works fine, sizeof(_Ty) returns 16, and everything is happy. But in this context, creating the params XmlRpcValue array, this same exact thing happens every time.
Anybody else have any insight on this?