opts_start_struct(Visitor *v, void **obj, const char *kind,

                  const char *name, size_t size, Error **errp)

{

    OptsVisitor *ov = DO_UPCAST(OptsVisitor, visitor, v);

    const QemuOpt *opt;



    *obj = g_malloc0(size > 0 ? size : 1);

    if (ov->depth++ > 0) {

        return;

    }



    ov->unprocessed_opts = g_hash_table_new_full(&g_str_hash, &g_str_equal,

                                                 NULL, &destroy_list);

    QTAILQ_FOREACH(opt, &ov->opts_root->head, next) {

        /* ensured by qemu-option.c::opts_do_parse() */

        assert(strcmp(opt->name, "id") != 0);



        opts_visitor_insert(ov->unprocessed_opts, opt);

    }



    if (ov->opts_root->id != NULL) {

        ov->fake_id_opt = g_malloc0(sizeof *ov->fake_id_opt);



        ov->fake_id_opt->name = "id";

        ov->fake_id_opt->str = ov->opts_root->id;

        opts_visitor_insert(ov->unprocessed_opts, ov->fake_id_opt);

    }

}

opts_start_struct(Visitor *v, void **obj, const char *kind,

                  const char *name, size_t size, Error **errp)

{

    OptsVisitor *ov = DO_UPCAST(OptsVisitor, visitor, v);

    const QemuOpt *opt;



    *obj = g_malloc0(size > 0 ? size : 1);

    if (ov->depth++ > 0) {

        return;

    }



    ov->unprocessed_opts = g_hash_table_new_full(&g_str_hash, &g_str_equal,

                                                 NULL, &destroy_list);

    QTAILQ_FOREACH(opt, &ov->opts_root->head, next) {

        

        assert(strcmp(opt->name, "id") != 0);



        opts_visitor_insert(ov->unprocessed_opts, opt);

    }



    if (ov->opts_root->id != NULL) {

        ov->fake_id_opt = g_malloc0(sizeof *ov->fake_id_opt);



        ov->fake_id_opt->name = "id";

        ov->fake_id_opt->str = ov->opts_root->id;

        opts_visitor_insert(ov->unprocessed_opts, ov->fake_id_opt);

    }

}

FUNC_0(Visitor *VAR_0, void **VAR_1, const char *VAR_2,

                  const char *VAR_3, size_t VAR_4, Error **VAR_5)

{

    OptsVisitor *ov = DO_UPCAST(OptsVisitor, visitor, VAR_0);

    const QemuOpt *VAR_6;



    *VAR_1 = g_malloc0(VAR_4 > 0 ? VAR_4 : 1);

    if (ov->depth++ > 0) {

        return;

    }



    ov->unprocessed_opts = g_hash_table_new_full(&g_str_hash, &g_str_equal,

                                                 NULL, &destroy_list);

    QTAILQ_FOREACH(VAR_6, &ov->opts_root->head, next) {

        

        assert(strcmp(VAR_6->VAR_3, "id") != 0);



        opts_visitor_insert(ov->unprocessed_opts, VAR_6);

    }



    if (ov->opts_root->id != NULL) {

        ov->fake_id_opt = g_malloc0(sizeof *ov->fake_id_opt);



        ov->fake_id_opt->VAR_3 = "id";

        ov->fake_id_opt->str = ov->opts_root->id;

        opts_visitor_insert(ov->unprocessed_opts, ov->fake_id_opt);

    }

}

FUNC_0(Visitor *VAR_0, void **VAR_1, const char *VAR_2,
const char *VAR_3, size_t VAR_4, Error **VAR_5)
{ OptsVisitor *ov = DO_UPCAST(OptsVisitor, visitor, VAR_0); const QemuOpt *VAR_6; *VAR_1 = g_malloc0(VAR_4 > 0 ? VAR_4 : 1); if (ov->depth++ > 0) { return; } ov->unprocessed_opts = g_hash_table_new_full(&g_str_hash, &g_str_equal,
NULL, &destroy_list); QTAILQ_FOREACH(VAR_6, &ov->opts_root->head, next) { assert(strcmp(VAR_6->VAR_3, "id") != 0); opts_visitor_insert(ov->unprocessed_opts, VAR_6); } if (ov->opts_root->id != NULL) { ov->fake_id_opt = g_malloc0(sizeof *ov->fake_id_opt); ov->fake_id_opt->VAR_3 = "id"; ov->fake_id_opt->str = ov->opts_root->id; opts_visitor_insert(ov->unprocessed_opts, ov->fake_id_opt); } }