[omniORB] Re: value type: Marshall error
Андрей Пучин
pouchin at gmail.com
Fri Sep 30 16:27:36 BST 2005
Thank you, Duncan, for complete explanation.
I will ask TAO developers.
Friday, September 30, 2005, 1:58:25 PM, you wrote:
> On Friday 30 September,
> =?Windows-1251?Q?=C0=ED=E4=F0=E5=E9_=CF=F3=F7=E8=ED?= wrote:
>> For example for IDL:
>> typedef any QueryAttributeValue;
>>
>> enum LogicOperation {
>> LO_OR
>> , LO_AND
>> , LO_NOT
>> };
>>
>> valuetype QueryDictData {
>> public LogicOperation operation;
>>
>> };
>>
>> interface SearchManager {
>> long search (in QueryAttributeValue search_query);
>> };
> [...]
> I'll explain the (partial) TypeCode...
>> 49 44 4c 3a 56 61 6c 75 65 54 65 73 74 2f 51 75 IDL:ValueTest/Qu
>> 65 72 79 44 69 63 74 44 61 74 61 3a 31 2e 30 00 eryDictData:1.0.
> This is the repository id. (You cut off the length field.)
>> 0e 00 00 00 51 75 65 72 79 44 69 63 74 44 61 74 ....QueryDictDat
>> 61 00
> This is the valuetype name, with terminating null
>> 00 00 00 00 00 00 01 00 00 00 0a 00 00 00 a...............
> Next comes the ValueModifier. It's a short, so the alignment is
> right without needing any padding. 00 00 is VM_NONE, meaning no value
> modifier.
> Next comes the concrete base TypeCode. The kind is 00 00 00 00,
> i.e. tk_null -- no concrete base.
> Next is count of members, 01 00 00 00 -- i.e. one member.
> Next is start of string for member name.
>> 6f 70 65 72 61 74 69 6f 6e 00 00 00 11 00 00 00 operation.......
> Member name, then pad, then tk_enum (and after that will be the rest of
> the enum TyepCode).
>> but tao client generates:
>>
>> -->message part skipped
>>
>> 49 44 4c 3a 56 61 6c 75 65 54 65 73 74 2f 51 75 IDL:ValueTest/Qu
>> 65 72 79 44 69 63 74 44 61 74 61 3a 31 2e 30 00 eryDictData:1.0.
>> 0e 00 00 00 51 75 65 72 79 44 69 63 74 44 61 74 ....QueryDictDat
>> 61 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 a...............
> ^^^^^ ^^^^^^^^^^^
> My guess is that TAO is treating the value modifier as a long, not a
> short. That means that the bits I've marked are first some padding, and
> then the modifier as a long.
>> Is this Tao or omni problem?
> I think it's a TAO problem. Have you asked the TAO developers?
> Cheers,
> Duncan.
--
Best regards,
Андрей mailto:pouchin at gmail.com
More information about the omniORB-list
mailing list