qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v4 17/20] console: make screendump asynchronous


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] [PATCH v4 17/20] console: make screendump asynchronous
Date: Wed, 10 Apr 2019 10:48:30 +0200
User-agent: NeoMutt/20180716

> +static void qmp_screendump_finish(QemuConsole *con, struct qmp_screendump 
> *dump)
> +{
> +    Error *err = NULL;
> +    DisplaySurface *surface;
> +    Monitor *prev_mon = cur_mon;

Why this is needed?

> +        /*
> +         * FIXME: async save with coroutine? it would have to copy or
> +         * lock the surface.
> +         */
> +        ppm_save(dump->filename, surface, &err);

DisplaySurface is just a thin layer above pixman images these days.
Pixman images are reference counted, so you can
pixman_image_ref(surface->image) to make sure it doesn't disappear
underneath you, then pass the pixman image to ppm_save.

cheers,
  Gerd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]