From 4ef6a090655cb5043a76c2afc9b15467606b7028 Mon Sep 17 00:00:00 2001 From: Dmitry Kalyanov Date: Thu, 6 Aug 2009 02:17:44 +0400 Subject: [PATCH] glib: fixed free-translated-object for variant cstruct --- glib/gobject.boxed.lisp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/glib/gobject.boxed.lisp b/glib/gobject.boxed.lisp index fe84adb..5afba92 100644 --- a/glib/gobject.boxed.lisp +++ b/glib/gobject.boxed.lisp @@ -444,12 +444,13 @@ (when proxy (let ((type (g-boxed-foreign-info foreign-type))) (multiple-value-bind (actual-struct cstruct-description) (decide-proxy-type type native) - (unless (eq (type-of proxy) (cstruct-description-name actual-struct)) + (unless (eq (type-of proxy) actual-struct) (restart-case (error "Expected type of boxed variant structure ~A and actual type ~A do not match" (type-of proxy) actual-struct) (skip-parsing-values () (return-from free-translated-object)))) - (copy-slots-to-proxy proxy native cstruct-description))))) + (copy-slots-to-proxy proxy native cstruct-description) + (boxed-free-fn type native))))) (defmethod translate-from-foreign (native (foreign-type boxed-variant-cstruct-foreign-type)) (unless (null-pointer-p native) -- 1.7.10.4