Changeset 4372b49 in mainline for uspace/srv/fs/fat/fat_directory.c
- Timestamp:
- 2011-06-21T12:02:24Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 9553d7d
- Parents:
- 563686b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/fat/fat_directory.c
r563686b r4372b49 41 41 #include <byteorder.h> 42 42 #include <mem.h> 43 #include <str.h> 43 44 44 45 int fat_directory_block_load(fat_directory_t *); … … 58 59 di->last = false; 59 60 60 di-> lfn_utf16[0] = '\0';61 di->wname[0] = '\0'; 61 62 di->lfn_offset = 0; 62 63 di->lfn_size = 0; … … 174 175 (di->checksum == FAT_LFN_CHKSUM(d))) { 175 176 /* Right order! */ 176 di->lfn_offset = fat_lfn_copy_entry(d, di->lfn_utf16, 177 di->lfn_offset); 177 fat_lfn_copy_entry(d, di->wname, &di->lfn_offset); 178 178 } else { 179 179 /* Something wrong with order. Skip this long entries set */ … … 190 190 (FAT_LFN_COUNT(d) - 1)) + fat_lfn_size(d); 191 191 di->lfn_offset = di->lfn_size; 192 di->lfn_offset = fat_lfn_copy_entry(d, di->lfn_utf16, 193 di->lfn_offset); 192 fat_lfn_copy_entry(d, di->wname, &di->lfn_offset); 194 193 di->checksum = FAT_LFN_CHKSUM(d); 195 194 } … … 200 199 if (di->long_entry && 201 200 (di->checksum == fat_dentry_chksum(d->name))) { 202 int rc; 203 rc = fat_lfn_convert_name(di->lfn_utf16, di->lfn_size, 204 (uint8_t*)name, FAT_LFN_NAME_SIZE); 205 if (rc!=EOK) 201 di->wname[di->lfn_size] = '\0'; 202 if (utf16_to_str(name, FAT_LFN_NAME_SIZE, di->wname)!=EOK) 206 203 fat_dentry_name_get(d, name); 207 204 }
Note:
See TracChangeset
for help on using the changeset viewer.