mirror of
https://github.com/ventoy/Ventoy.git
synced 2024-09-19 07:28:46 -04:00
Fix the menu missing issue when there exist an invalid vlnk file. (#2228)
This commit is contained in:
parent
2717405a7a
commit
7fa4724743
2 changed files with 9 additions and 0 deletions
|
@ -392,6 +392,11 @@ static int ventoy_browser_iterate_dir(const char *filename, const struct grub_di
|
|||
return 0;
|
||||
}
|
||||
|
||||
if (grub_file_is_vlnk_suffix(filename, len))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
node = grub_zalloc(sizeof(browser_node));
|
||||
if (!node)
|
||||
{
|
||||
|
|
|
@ -1767,6 +1767,10 @@ static int ventoy_check_vlnk_data(ventoy_vlnk *vlnk, int print, char *dst, int s
|
|||
cur->fs->fs_close(&file);
|
||||
grub_snprintf(dst, size - 1, "(%s)%s", cur->device, vlnk->filepath);
|
||||
}
|
||||
else
|
||||
{
|
||||
grub_errno = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue