]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
D-Bus: Fix crash on interfaces without methods in GDBus servers
authorJürg Billeter <j@bitron.ch>
Sat, 23 Oct 2010 19:51:13 +0000 (21:51 +0200)
committerJürg Billeter <j@bitron.ch>
Sat, 23 Oct 2010 19:51:13 +0000 (21:51 +0200)
codegen/valagdbusservermodule.vala

index 9f8813b3ed068e363ee5d827fa367fee6f4155f8..51a6869cb6cea1aa90f004999a79b32e19eca4a0 100644 (file)
@@ -650,7 +650,9 @@ public class Vala.GDBusServerModule : GDBusClientModule {
                        ccode.add_expression (ccall);
                }
 
-               ccode.close ();
+               if (!first) {
+                       ccode.close ();
+               }
 
                var ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_object_unref"));
                ccall.add_argument (new CCodeIdentifier ("invocation"));