[Spice-devel] [PATCH spice 1/2] agent-filter: Constantify parameter

Pavel Grunt pgrunt at redhat.com
Mon Sep 12 12:13:49 UTC 2016


Filter should not modify data
---
 server/agent-msg-filter.c | 2 +-
 server/agent-msg-filter.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/server/agent-msg-filter.c b/server/agent-msg-filter.c
index 3e5b225..a11f624 100644
--- a/server/agent-msg-filter.c
+++ b/server/agent-msg-filter.c
@@ -49,7 +49,7 @@ void agent_msg_filter_init(AgentMsgFilter *filter,
 }
 
 int agent_msg_filter_process_data(AgentMsgFilter *filter,
-                                  uint8_t *data, uint32_t len)
+                                  const uint8_t *data, uint32_t len)
 {
     struct VDAgentMessage msg_header;
 
diff --git a/server/agent-msg-filter.h b/server/agent-msg-filter.h
index e7eef1a..d61f8d4 100644
--- a/server/agent-msg-filter.h
+++ b/server/agent-msg-filter.h
@@ -50,6 +50,6 @@ void agent_msg_filter_config(AgentMsgFilter *filter,
                              gboolean copy_paste, gboolean file_xfer,
                              gboolean use_client_monitors_config);
 int agent_msg_filter_process_data(AgentMsgFilter *filter,
-                                  uint8_t *data, uint32_t len);
+                                  const uint8_t *data, uint32_t len);
 
 #endif
-- 
2.10.0



More information about the Spice-devel mailing list