* grub-core/fs/iso9660.c (grub_iso9660_iterate_dir): Don't strrchr
through UTF-16.
This commit is contained in:
parent
0c6c324e90
commit
8ad3f28cec
2 changed files with 16 additions and 12 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2012-05-17 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* grub-core/fs/iso9660.c (grub_iso9660_iterate_dir): Don't strrchr
|
||||||
|
through UTF-16.
|
||||||
|
|
||||||
2012-05-17 Vladimir Serbinenko <phcoder@gmail.com>
|
2012-05-17 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
* grub-core/fs/fat.c (grub_fat_find_dir): Fix error message.
|
* grub-core/fs/fat.c (grub_fat_find_dir): Fix error message.
|
||||||
|
|
|
@ -725,30 +725,29 @@ grub_iso9660_iterate_dir (grub_fshelp_node_t dir,
|
||||||
type = GRUB_FSHELP_REG;
|
type = GRUB_FSHELP_REG;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* . and .. */
|
||||||
|
if (!filename && dirent.namelen == 1 && (name[0] == ';' || name[0] == 0 || name[0] == 1))
|
||||||
|
{
|
||||||
|
grub_free (node);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
/* The filename was not stored in a rock ridge entry. Read it
|
/* The filename was not stored in a rock ridge entry. Read it
|
||||||
from the iso9660 filesystem. */
|
from the iso9660 filesystem. */
|
||||||
if (!filename)
|
if (!dir->data->joliet && !filename)
|
||||||
{
|
{
|
||||||
name[dirent.namelen] = '\0';
|
name[dirent.namelen] = '\0';
|
||||||
filename = grub_strrchr (name, ';');
|
filename = grub_strrchr (name, ';');
|
||||||
if (filename)
|
if (filename)
|
||||||
*filename = '\0';
|
*filename = '\0';
|
||||||
|
|
||||||
/* . and .. */
|
|
||||||
if (dirent.namelen == 1 && (name[0] == 0 || name[0] == 1))
|
|
||||||
{
|
|
||||||
grub_free (node);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
filename = name;
|
filename = name;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dir->data->joliet)
|
if (dir->data->joliet && !filename)
|
||||||
{
|
{
|
||||||
char *oldname, *semicolon;
|
char *oldname, *semicolon;
|
||||||
|
|
||||||
oldname = filename;
|
oldname = name;
|
||||||
filename = grub_iso9660_convert_string
|
filename = grub_iso9660_convert_string
|
||||||
((grub_uint8_t *) oldname, dirent.namelen >> 1);
|
((grub_uint8_t *) oldname, dirent.namelen >> 1);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue