]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
D-Bus: Fix string-marshalled enum handling in async GDBus servers
authorJürg Billeter <j@bitron.ch>
Sat, 15 Jan 2011 13:06:39 +0000 (14:06 +0100)
committerJürg Billeter <j@bitron.ch>
Sat, 15 Jan 2011 13:07:03 +0000 (14:07 +0100)
codegen/valagdbusservermodule.vala

index 327954010016a7ee23c4c6051f06327449d3e76e..c9c7c03f33c65725e70abe6c2ce3645da9be7210 100644 (file)
@@ -90,7 +90,7 @@ public class Vala.GDBusServerModule : GDBusClientModule {
                bool uses_error = false;
 
                if (!m.coroutine || ready) {
-                       ccode.add_declaration ("GError*", new CCodeVariableDeclarator ("error", new CCodeConstant ("NULL")));
+                       ccode.add_declaration ("GError*", new CCodeVariableDeclarator.zero ("error", new CCodeConstant ("NULL")));
                        uses_error = true;
                }
 
@@ -154,7 +154,7 @@ public class Vala.GDBusServerModule : GDBusClientModule {
 
                                if (may_fail) {
                                        if (!uses_error) {
-                                               ccode.add_declaration ("GError*", new CCodeVariableDeclarator ("error", new CCodeConstant ("NULL")));
+                                               ccode.add_declaration ("GError*", new CCodeVariableDeclarator.zero ("error", new CCodeConstant ("NULL")));
                                                uses_error = true;
                                        }