summaryrefslogtreecommitdiffstats
path: root/server/agent-msg-filter.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2012-03-14 19:34:35 +0100
committerMarc-André Lureau <marcandre.lureau@redhat.com>2012-03-25 19:00:00 +0200
commitb34fd7432d61b992446a3cd9c6f8eb7747ba0a76 (patch)
tree60a5b34a3e37177ea6a54da9fd8d2b475bfe9257 /server/agent-msg-filter.c
parent359fc1cb5dbbcf32132c3e8ee6f881a23deff684 (diff)
downloadspice-b34fd7432d61b992446a3cd9c6f8eb7747ba0a76.tar.gz
spice-b34fd7432d61b992446a3cd9c6f8eb7747ba0a76.tar.xz
spice-b34fd7432d61b992446a3cd9c6f8eb7747ba0a76.zip
Use the spice-common logging functions
It will abort by default for critical level messages. That behaviour can be tuned at runtime.
Diffstat (limited to 'server/agent-msg-filter.c')
-rw-r--r--server/agent-msg-filter.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/agent-msg-filter.c b/server/agent-msg-filter.c
index 71ff49b7..7584b52f 100644
--- a/server/agent-msg-filter.c
+++ b/server/agent-msg-filter.c
@@ -39,7 +39,7 @@ int agent_msg_filter_process_data(struct AgentMsgFilter *filter,
struct VDAgentMessage msg_header;
if (len > VD_AGENT_MAX_DATA_SIZE) {
- red_printf("invalid agent message: too large");
+ spice_printerr("invalid agent message: too large");
return AGENT_MSG_FILTER_PROTO_ERROR;
}
@@ -47,7 +47,7 @@ int agent_msg_filter_process_data(struct AgentMsgFilter *filter,
if (filter->msg_data_to_read) {
data_to_read:
if (len > filter->msg_data_to_read) {
- red_printf("invalid agent message: data exceeds size from header");
+ spice_printerr("invalid agent message: data exceeds size from header");
return AGENT_MSG_FILTER_PROTO_ERROR;
}
filter->msg_data_to_read -= len;
@@ -55,14 +55,14 @@ data_to_read:
}
if (len < sizeof(msg_header)) {
- red_printf("invalid agent message: incomplete header");
+ spice_printerr("invalid agent message: incomplete header");
return AGENT_MSG_FILTER_PROTO_ERROR;
}
memcpy(&msg_header, data, sizeof(msg_header));
len -= sizeof(msg_header);
if (msg_header.protocol != VD_AGENT_PROTOCOL) {
- red_printf("invalid agent protocol: %u", msg_header.protocol);
+ spice_printerr("invalid agent protocol: %u", msg_header.protocol);
return AGENT_MSG_FILTER_PROTO_ERROR;
}