static void qemu_chr_parse_file_out(QemuOpts *opts, ChardevBackend *backend,

                                    Error **errp)

{

    const char *path = qemu_opt_get(opts, "path");

    ChardevFile *file;



    if (path == NULL) {

        error_setg(errp, "chardev: file: no filename given");

        return;

    }

    file = backend->u.file = g_new0(ChardevFile, 1);

    qemu_chr_parse_common(opts, qapi_ChardevFile_base(file));

    file->out = g_strdup(path);



    file->has_append = true;

    file->append = qemu_opt_get_bool(opts, "append", false);

}

static void qemu_chr_parse_file_out(QemuOpts *opts, ChardevBackend *backend,

                                    Error **errp)

{

    const char *path = qemu_opt_get(opts, "path");

    ChardevFile *file;



    if (path == NULL) {

        error_setg(errp, "chardev: file: no filename given");

        return;

    }

    file = backend->u.file = g_new0(ChardevFile, 1);

    qemu_chr_parse_common(opts, qapi_ChardevFile_base(file));

    file->out = g_strdup(path);



    file->has_append = true;

    file->append = qemu_opt_get_bool(opts, "append", false);

}

static void FUNC_0(QemuOpts *VAR_0, ChardevBackend *VAR_1,

                                    Error **VAR_2)

{

    const char *VAR_3 = qemu_opt_get(VAR_0, "VAR_3");

    ChardevFile *file;



    if (VAR_3 == NULL) {

        error_setg(VAR_2, "chardev: file: no filename given");

        return;

    }

    file = VAR_1->u.file = g_new0(ChardevFile, 1);

    qemu_chr_parse_common(VAR_0, qapi_ChardevFile_base(file));

    file->out = g_strdup(VAR_3);



    file->has_append = true;

    file->append = qemu_opt_get_bool(VAR_0, "append", false);

}

static void FUNC_0(QemuOpts *VAR_0, ChardevBackend *VAR_1,
Error **VAR_2)
{ const char *VAR_3 = qemu_opt_get(VAR_0, "VAR_3"); ChardevFile *file; if (VAR_3 == NULL) { error_setg(VAR_2, "chardev: file: no filename given"); return; } file = VAR_1->u.file = g_new0(ChardevFile, 1); qemu_chr_parse_common(VAR_0, qapi_ChardevFile_base(file)); file->out = g_strdup(VAR_3); file->has_append = true; file->append = qemu_opt_get_bool(VAR_0, "append", false); }