[Spice-devel] [vdagent-win PATCH 1/2] vdagent: add support for VD_AGENT_CLIENT_DISCONNECTED

Hans de Goede hdegoede at redhat.com
Wed May 8 08:43:19 PDT 2013


Looks good, ack series.

On 05/08/2013 05:01 PM, Arnon Gilboa wrote:
> vdagent is stopped, so a new instance is to be launched by vdservice.
> imho, this seems simpler than cleaning agent in/out msg state and
> reseting the vio-serial device to cleanup pending msgs.
>
> rhbz #956133
> ---
>   vdagent/vdagent.cpp |    4 ++++
>   1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/vdagent/vdagent.cpp b/vdagent/vdagent.cpp
> index 118cafd..1fad0e6 100644
> --- a/vdagent/vdagent.cpp
> +++ b/vdagent/vdagent.cpp
> @@ -1226,6 +1226,10 @@ void VDAgent::dispatch_message(VDAgentMessage* msg, uint32_t port)
>       case VD_AGENT_ANNOUNCE_CAPABILITIES:
>           res = a->handle_announce_capabilities((VDAgentAnnounceCapabilities*)msg->data, msg->size);
>           break;
> +    case VD_AGENT_CLIENT_DISCONNECTED:
> +        vd_printf("Client disconnected, agent to be restarted");
> +        a->set_control_event(CONTROL_STOP);
> +        break;
>       default:
>           vd_printf("Unsupported message type %u size %u", msg->type, msg->size);
>       }
>


More information about the Spice-devel mailing list