[Spice-devel] [PATCH 03/30] Add compress_buf_free function
Frediano Ziglio
fziglio at redhat.com
Tue Jun 7 10:17:41 UTC 2016
dcc-encoders should be in change of allocate and free the structure
don't put internal assumptions (which functions are used for memory
management) in different files.
Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
---
server/dcc-encoders.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/server/dcc-encoders.h b/server/dcc-encoders.h
index fed8d58..e4eabc0 100644
--- a/server/dcc-encoders.h
+++ b/server/dcc-encoders.h
@@ -64,6 +64,11 @@ struct RedCompressBuf {
RedCompressBuf *send_next;
};
+static inline void compress_buf_free(RedCompressBuf *buf)
+{
+ g_free(buf);
+}
+
typedef struct GlzSharedDictionary {
RingItem base;
GlzEncDictContext *dict;
--
2.7.4
More information about the Spice-devel
mailing list