Legacy Issue Number: 5941
Source: Oracle ( Andrew Piper)
Although I now think I know the intent of the spec, its is ambiguous if not plain wrong with respect to valuetype fragmentation.
In particular 22.214.171.124:
Bullet 1 says:
"End tags, chunk size tags, and value tags are encoded using non-overlapping ranges
so that the unmarshaling code can tell after reading each chunk whether:
another chunk follows (positive tag).
one or multiple value types are ending at a given point in the stream (negative
a nested value follows (special large positive tag)."
Bullet 3 says:
" For the purposes of chunking, values encoded as indirections or null are treated as
And the pseudo-BNF says:
"(1) <value> ::= <value_tag> [ <codebase_URL> ]
[ <type_info> ] <state>
(2) <value_ref> ::= <indirection_tag> <indirection>
(3) <value_tag> ::= long// 0x7fffff00 <= value_tag <= 0x7fffffff
(4) <type_info> ::= <rep_ids>
(5) <state> ::= <octets>
<value_data>* [ <end_tag> ]
(6) <value_data> ::= <value_chunk>
Now clearly the implication of bullet 1 is that an indirection or null must appear inside a chunk in a chunked encoding, otherwise you would be able to see the value 0 or -1 after a chunk and the -1 in particular could mean an end tag or an indirection. However the possible implication of bullet 3 and the BNF (note the use of "value data") is that nulls and indirections are values and thus must appear outside of chunks. Clearly the former interpretation is the correct one otherwise anarchy ensues.
So I propose that we change the 3rd bullet to say:
"For the purposes of chunking, values encoded as indirections or null are treated as
if they were not values and therefore must always appear inside a chunk when a chunked encoding is in effect."
and then change the BNF to say:
"(1) <value> ::= <concrete_value> | <value_ref>
(2) <concrete_value> ::= <value_tag> [ <codebase_URL> ]
[ <type_info> ] <state>
(3) <value_ref> ::= <indirection_tag> <indirection> | <null_tag>
(4) <value_tag> ::= long// 0x7fffff00 <= value_tag <= 0x7fffffff
(5) <type_info> ::= <rep_ids> | <repository_id>
(6) <state> ::= <octets> |<value_data>* [ <end_tag> ]
(7) <value_data> ::= <value_chunk> | <concrete_value>"
Reported: CORBA 3.0.2 — Fri, 23 May 2003 04:00 GMT
Disposition: Deferred — CORBA 3.4
This proposal was generated automatically by request of the Task Force Chair Adam Mitz.
Updated: Mon, 30 Mar 2020 19:47 GMT