diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2016-12-08 16:34:16 +0300 |
---|---|---|
committer | Marc-André Lureau <marcandre.lureau@redhat.com> | 2017-01-31 13:01:46 +0400 |
commit | 18c508acdbdb7ef21837d1ce0d75c9d9c55381f6 (patch) | |
tree | 12dccfd4d8b071df65cab4c683887d99ce607abe /spice-qemu-char.c | |
parent | 55fc84a7a3f6f481cc3dab63c8db4f3b5373c139 (diff) | |
download | qemu-18c508acdbdb7ef21837d1ce0d75c9d9c55381f6.zip qemu-18c508acdbdb7ef21837d1ce0d75c9d9c55381f6.tar.gz qemu-18c508acdbdb7ef21837d1ce0d75c9d9c55381f6.tar.bz2 |
spice-qemu-char: convert to finalize
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'spice-qemu-char.c')
-rw-r--r-- | spice-qemu-char.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spice-qemu-char.c b/spice-qemu-char.c index dd97c17..3902202 100644 --- a/spice-qemu-char.c +++ b/spice-qemu-char.c @@ -210,9 +210,9 @@ static int spice_chr_write(Chardev *chr, const uint8_t *buf, int len) return read_bytes; } -static void spice_chr_free(struct Chardev *chr) +static void char_spice_finalize(Object *obj) { - SpiceChardev *s = SPICE_CHARDEV(chr); + SpiceChardev *s = SPICE_CHARDEV(obj); vmc_unregister_interface(s); QLIST_REMOVE(s, next); @@ -365,13 +365,13 @@ static void char_spice_class_init(ObjectClass *oc, void *data) cc->chr_write = spice_chr_write; cc->chr_add_watch = spice_chr_add_watch; cc->chr_accept_input = spice_chr_accept_input; - cc->chr_free = spice_chr_free; } static const TypeInfo char_spice_type_info = { .name = TYPE_CHARDEV_SPICE, .parent = TYPE_CHARDEV, .instance_size = sizeof(SpiceChardev), + .instance_finalize = char_spice_finalize, .class_init = char_spice_class_init, .abstract = true, }; |