metadata: append_sorted should really append sorted

... which means that identical offset_orig should preserve the order
in which they are appended.
This commit is contained in:
Mark Nauwelaerts 2010-02-05 10:18:39 +01:00
parent 5f4f24fb76
commit a6ba273e36

View file

@ -178,7 +178,7 @@ metadata_chunk_array_append_sorted (MetadataChunkArray * array,
} }
pos = array->len; pos = array->len;
for (i = array->len - 1; i >= 0; --i) { for (i = array->len - 1; i >= 0; --i) {
if (chunk->offset_orig > array->chunk[i].offset_orig) { if (chunk->offset_orig >= array->chunk[i].offset_orig) {
break; break;
} }
} }