* grub-core/fs/fshelp.c (find_file): Save ctx->next when calling
find_file recursively for symlink.
This commit is contained in:
parent
8b3e6eb6b6
commit
1397f0b520
2 changed files with 8 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2013-11-02 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* grub-core/fs/fshelp.c (find_file): Save ctx->next when calling
|
||||||
|
find_file recursively for symlink.
|
||||||
|
|
||||||
2013-11-02 Vladimir Serbinenko <phcoder@gmail.com>
|
2013-11-02 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
* tests/util/grub-shell.in: Copy themes.
|
* tests/util/grub-shell.in: Copy themes.
|
||||||
|
|
|
@ -133,6 +133,7 @@ find_file (const char *currpath, grub_fshelp_node_t currroot,
|
||||||
if (ctx->type == GRUB_FSHELP_SYMLINK)
|
if (ctx->type == GRUB_FSHELP_SYMLINK)
|
||||||
{
|
{
|
||||||
char *symlink;
|
char *symlink;
|
||||||
|
const char *next;
|
||||||
|
|
||||||
/* Test if the symlink does not loop. */
|
/* Test if the symlink does not loop. */
|
||||||
if (++ctx->symlinknest == 8)
|
if (++ctx->symlinknest == 8)
|
||||||
|
@ -164,8 +165,10 @@ find_file (const char *currpath, grub_fshelp_node_t currroot,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Lookup the node the symlink points to. */
|
/* Lookup the node the symlink points to. */
|
||||||
|
next = ctx->next;
|
||||||
find_file (symlink, ctx->oldnode, &ctx->currnode,
|
find_file (symlink, ctx->oldnode, &ctx->currnode,
|
||||||
iterate_dir, read_symlink, ctx);
|
iterate_dir, read_symlink, ctx);
|
||||||
|
ctx->next = next;
|
||||||
ctx->type = ctx->foundtype;
|
ctx->type = ctx->foundtype;
|
||||||
grub_free (symlink);
|
grub_free (symlink);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue