Add log for invalid/expired tickets

Currently, when a ticket has already expired, or is invalid, there is
no qemu log to tell what went wrong. This commit adds such a log.

Fixes rhbz#787669
This commit is contained in:
Christophe Fergeau 2012-03-01 18:46:24 +01:00
parent 735f8e2837
commit 8f8e73986b

View File

@ -1860,6 +1860,11 @@ static void reds_handle_ticket(void *opaque)
}
if (expired || strncmp(password, taTicket.password, SPICE_MAX_PASSWORD_LENGTH) != 0) {
if (expired) {
red_printf("Ticket has expired");
} else {
red_printf("Invalid password");
}
reds_send_link_result(link, SPICE_LINK_ERR_PERMISSION_DENIED);
reds_link_free(link);
return;