mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-08 06:53:45 +00:00
ICU-4449 Fix for EBCDIC platforms. Calculate the offsets correctly.
X-SVN-Rev: 18090
This commit is contained in:
parent
15f1fe57a6
commit
d6080ceac5
1 changed files with 3 additions and 1 deletions
|
@ -708,6 +708,9 @@ udata_swapPackage(const UDataSwapper *ds,
|
|||
table[itemCount-1].length+=(uint32_t)delta;
|
||||
}
|
||||
|
||||
/* Save the offset before we sort the TOC. */
|
||||
offset=table[0].inOffset;
|
||||
/* sort the TOC entries */
|
||||
uprv_sortArray(table, (int32_t)itemCount, (int32_t)sizeof(ToCEntry),
|
||||
compareToCEntries, outBytes, FALSE, pErrorCode);
|
||||
|
||||
|
@ -717,7 +720,6 @@ udata_swapPackage(const UDataSwapper *ds,
|
|||
*/
|
||||
|
||||
/* assign outOffset values */
|
||||
offset=table[0].inOffset;
|
||||
for(i=0; i<itemCount; ++i) {
|
||||
table[i].outOffset=offset;
|
||||
offset+=table[i].length;
|
||||
|
|
Loading…
Add table
Reference in a new issue