server/reds: don't remove agent if it's not connected

This commit is contained in:
Alon Levy 2010-11-08 12:37:15 +02:00
parent 26cd666be5
commit e7e667f81d

View File

@ -2537,7 +2537,7 @@ static void spice_server_char_device_remove_interface(SpiceBaseInstance *sin)
red_printf("remove CHAR_DEVICE %s", char_device->subtype);
if (strcmp(char_device->subtype, SUBTYPE_VDAGENT) == 0) {
if (vdagent) {
if (vdagent && reds->agent_state.connected) {
reds_agent_remove();
}
}