Changeset ab936440 in mainline for uspace/srv/fs/udf/udf_file.c
- Timestamp:
- 2019-02-12T20:42:42Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- f31ca47
- Parents:
- 7f7817a9 (diff), 4805495 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Matthieu Riolo <matthieu.riolo@…> (2019-02-12 20:26:18)
- git-committer:
- Matthieu Riolo <matthieu.riolo@…> (2019-02-12 20:42:42)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/udf/udf_file.c
r7f7817a9 rab936440 114 114 if ((node->index >= node->instance->partitions[i].start) && 115 115 (node->index < node->instance->partitions[i].start + 116 node->instance->partitions[i].leng ht)) {116 node->instance->partitions[i].length)) { 117 117 if (node->instance->partitions[i].start >= min_start) { 118 118 min_start = node->instance->partitions[i].start; … … 258 258 (udf_file_entry_descriptor_t *) block->data; 259 259 uint16_t icb_flag = FLE16(file->icbtag.flags) & UDF_ICBFLAG_MASK; 260 node->data_size = FLE64(file->info_leng ht);260 node->data_size = FLE64(file->info_length); 261 261 node->type = (file->icbtag.file_type == UDF_ICBTYPE_DIR) ? NODE_DIR : NODE_FILE; 262 262 263 263 rc = udf_read_allocation_sequence(node, (uint8_t *) file, icb_flag, 264 FLE32(file->ea_leng ht) + UDF_FE_OFFSET, FLE32(file->ad_lenght));264 FLE32(file->ea_length) + UDF_FE_OFFSET, FLE32(file->ad_length)); 265 265 block_put(block); 266 266 return rc; … … 272 272 (udf_extended_file_entry_descriptor_t *) block->data; 273 273 icb_flag = FLE16(efile->icbtag.flags) & UDF_ICBFLAG_MASK; 274 node->data_size = FLE64(efile->info_leng ht);274 node->data_size = FLE64(efile->info_length); 275 275 node->type = (efile->icbtag.file_type == UDF_ICBTYPE_DIR) ? NODE_DIR : NODE_FILE; 276 276 277 277 rc = udf_read_allocation_sequence(node, (uint8_t *) efile, icb_flag, 278 FLE32(efile->ea_leng ht) + UDF_EFE_OFFSET, FLE32(efile->ad_lenght));278 FLE32(efile->ea_length) + UDF_EFE_OFFSET, FLE32(efile->ad_length)); 279 279 block_put(block); 280 280 return rc; … … 338 338 339 339 /* According to ECMA 167 4/14.4.9 */ 340 size_t padding = 4 * (((*fid)->leng ht_file_id +341 FLE16((*fid)->leng ht_iu) + 38 + 3) / 4) -342 ((*fid)->leng ht_file_id + FLE16((*fid)->lenght_iu) + 38);343 size_t size_fid = (*fid)->leng ht_file_id +344 FLE16((*fid)->leng ht_iu) + padding + 38;340 size_t padding = 4 * (((*fid)->length_file_id + 341 FLE16((*fid)->length_iu) + 38 + 3) / 4) - 342 ((*fid)->length_file_id + FLE16((*fid)->length_iu) + 38); 343 size_t size_fid = (*fid)->length_file_id + 344 FLE16((*fid)->length_iu) + padding + 38; 345 345 346 346 fid_sum += size_fid; 347 347 348 348 /* aAcording to ECMA 167 4/8.6 */ 349 if (((*fid)->leng ht_file_id != 0) &&349 if (((*fid)->length_file_id != 0) && 350 350 (((*fid)->file_characteristics & 4) == 0)) { 351 351 n++; … … 516 516 517 517 /* According to ECMA 167 4/14.4.9 */ 518 size_t padding = 4 * (((*fid)->leng ht_file_id +519 FLE16((*fid)->leng ht_iu) + 38 + 3) / 4) -520 ((*fid)->leng ht_file_id + FLE16((*fid)->lenght_iu) + 38);521 size_t size_fid = (*fid)->leng ht_file_id +522 FLE16((*fid)->leng ht_iu) + padding + 38;518 size_t padding = 4 * (((*fid)->length_file_id + 519 FLE16((*fid)->length_iu) + 38 + 3) / 4) - 520 ((*fid)->length_file_id + FLE16((*fid)->length_iu) + 38); 521 size_t size_fid = (*fid)->length_file_id + 522 FLE16((*fid)->length_iu) + padding + 38; 523 523 if (buf_flag) 524 524 fid_sum += size_fid - *len; … … 527 527 528 528 /* According to ECMA 167 4/8.6 */ 529 if (((*fid)->leng ht_file_id != 0) &&529 if (((*fid)->length_file_id != 0) && 530 530 (((*fid)->file_characteristics & 4) == 0)) { 531 531 (*n)++;
Note:
See TracChangeset
for help on using the changeset viewer.