* grub-core/fs/jfs.c (grub_jfs_data): New field caseins.
(grub_jfs_mount): Fill caseins. (grub_jfs_find_file): Respect caseins.
This commit is contained in:
parent
8ad3f28cec
commit
197626b569
2 changed files with 14 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2012-05-17 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/fs/jfs.c (grub_jfs_data): New field caseins.
|
||||
(grub_jfs_mount): Fill caseins.
|
||||
(grub_jfs_find_file): Respect caseins.
|
||||
|
||||
2012-05-17 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/fs/iso9660.c (grub_iso9660_iterate_dir): Don't strrchr
|
||||
|
|
|
@ -219,6 +219,7 @@ struct grub_jfs_data
|
|||
grub_disk_t disk;
|
||||
struct grub_jfs_inode fileset;
|
||||
struct grub_jfs_inode currinode;
|
||||
int caseins;
|
||||
int pos;
|
||||
int linknest;
|
||||
int namecomponentlen;
|
||||
|
@ -389,6 +390,11 @@ grub_jfs_mount (grub_disk_t disk)
|
|||
else
|
||||
data->namecomponentlen = 13;
|
||||
|
||||
if (data->sblock.flags & grub_cpu_to_le32_compile_time (0x40000000))
|
||||
data->caseins = 1;
|
||||
else
|
||||
data->caseins = 0;
|
||||
|
||||
return data;
|
||||
|
||||
fail:
|
||||
|
@ -674,7 +680,8 @@ grub_jfs_find_file (struct grub_jfs_data *data, const char *path,
|
|||
|
||||
/* Check if the current direntry matches the current part of the
|
||||
pathname. */
|
||||
if (!grub_strcmp (name, diro->name))
|
||||
if (data->caseins ? grub_strcasecmp (name, diro->name) == 0
|
||||
: grub_strcmp (name, diro->name) == 0)
|
||||
{
|
||||
grub_uint32_t ino = diro->ino;
|
||||
grub_uint32_t dirino = grub_le_to_cpu32 (data->currinode.inode);
|
||||
|
|
Loading…
Add table
Reference in a new issue