argv->argv[i++] = word->text;
}
-int statements_execute(struct grub2_script *script,
+static int statements_execute(struct grub2_script *script,
struct grub2_statements *stmts)
{
struct grub2_statement *stmt;
statements_execute(script, script->statements);
}
-struct grub2_script *create_script(void *ctx)
+struct grub2_script *create_script(struct grub2_parser *parser,
+ struct discover_context *ctx)
{
struct grub2_script *script;
- script = talloc(ctx, struct grub2_script);
+ script = talloc(parser, struct grub2_script);
init_env(script);
+ script->ctx = ctx;
+
list_init(&script->commands);
register_builtins(script);