mirror of
https://github.com/AdaCore/PolyORB.git
synced 2026-02-12 13:01:15 -08:00
(Unmarshall_To_Any): The expected aggregate element count for a
sequence is Length + 1, because the length is added as the first element of the aggregate. Fix incorrect computation of the expected length accordingly. [Imported from Perforce change 9428 at 2006-12-01 21:44:16] Subversion-branch: /trunk/polyorb Subversion-revision: 36914
This commit is contained in:
@@ -1883,7 +1883,7 @@ package body PolyORB.Representations.CDR is
|
||||
end if;
|
||||
|
||||
if Is_Empty (Data)
|
||||
or else Get_Aggregate_Count (Data) /= Len
|
||||
or else Get_Aggregate_Count (Data) /= Len + 1
|
||||
then
|
||||
Move_Any_Value (Data,
|
||||
Get_Empty_Any_Aggregate (Get_Type (Data)));
|
||||
@@ -1895,7 +1895,8 @@ package body PolyORB.Representations.CDR is
|
||||
|
||||
pragma Debug
|
||||
(O ("Unmarshall_To_Any: unmarshalling"
|
||||
& Unsigned_Long'Image (Len) & " elements"));
|
||||
& Unsigned_Long'Image (Len) & " elements, "
|
||||
& "Add_Elements = " & Boolean'Image (Add_Elements)));
|
||||
|
||||
for J in 1 .. Len loop
|
||||
if Add_Elements then
|
||||
|
||||
Reference in New Issue
Block a user