[Spice-commits] server/smartcard-channel-client.c

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Feb 11 13:09:48 UTC 2019


 server/smartcard-channel-client.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

New commits:
commit fd72b949650fafae8d6d5712fa821d02855f946c
Author: Frediano Ziglio <fziglio at redhat.com>
Date:   Mon Feb 11 11:13:17 2019 +0000

    smartcard-channel-client: Update usage of GObject private structures
    
    This finished the work of 90ff154b36b3ab80350cb4a4d391db330bed2a76
    (cfr "Update usage of GObject private structures").
    Removes last call to g_type_class_add_private.
    
    Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
    Acked-by: Eduardo Lima (Etrunko) <etrunko at redhat.com>

diff --git a/server/smartcard-channel-client.c b/server/smartcard-channel-client.c
index a665e933..daa20ffc 100644
--- a/server/smartcard-channel-client.c
+++ b/server/smartcard-channel-client.c
@@ -20,8 +20,6 @@
 
 #include "smartcard-channel-client.h"
 
-G_DEFINE_TYPE(SmartCardChannelClient, smart_card_channel_client, RED_TYPE_CHANNEL_CLIENT)
-
 struct SmartCardChannelClientPrivate
 {
     RedCharDeviceSmartcard *smartcard;
@@ -33,6 +31,9 @@ struct SmartCardChannelClientPrivate
                            * or was it explicitly malloced */
 };
 
+G_DEFINE_TYPE_WITH_PRIVATE(SmartCardChannelClient, smart_card_channel_client,
+                           RED_TYPE_CHANNEL_CLIENT)
+
 typedef struct RedErrorItem {
     RedPipeItem base;
     VSCMsgHeader vheader;
@@ -84,8 +85,6 @@ static void smart_card_channel_client_class_init(SmartCardChannelClientClass *kl
 {
     GObjectClass *object_class = G_OBJECT_CLASS(klass);
 
-    g_type_class_add_private(klass, sizeof(SmartCardChannelClientPrivate));
-
     RedChannelClientClass *client_class = RED_CHANNEL_CLIENT_CLASS(klass);
     client_class->alloc_recv_buf = smartcard_channel_client_alloc_msg_rcv_buf;
     client_class->release_recv_buf = smartcard_channel_client_release_msg_rcv_buf;


More information about the Spice-commits mailing list