Support disabling sentinels, patch by Sam Liddicott, fixes bug 548248
authorJürg Billeter <j@bitron.ch>
Tue, 16 Sep 2008 12:14:10 +0000 (12:14 +0000)
committerJürg Billeter <juergbi@src.gnome.org>
Tue, 16 Sep 2008 12:14:10 +0000 (12:14 +0000)
2008-09-16  Jürg Billeter  <j@bitron.ch>

* gobject/valaccodeinvocationexpressionbinding.vala:

Support disabling sentinels, patch by Sam Liddicott,
fixes bug 548248

svn path=/trunk/; revision=1771

ChangeLog
gobject/valaccodeinvocationexpressionbinding.vala

index e0fd437..5f20f75 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2008-09-16  Jürg Billeter  <j@bitron.ch>
 
+       * gobject/valaccodeinvocationexpressionbinding.vala:
+
+       Support disabling sentinels, patch by Sam Liddicott,
+       fixes bug 548248
+
+2008-09-16  Jürg Billeter  <j@bitron.ch>
+
        * vapi/glib-2.0.vapi:
 
        GScanner binding fixes, patch by Matías De la Puente,
index a133834..744216a 100644 (file)
@@ -392,7 +392,7 @@ public class Vala.CCodeInvocationExpressionBinding : CCodeExpressionBinding {
                if (ellipsis) {
                        /* ensure variable argument list ends with NULL
                         * except when using printf-style arguments */
-                       if ((m == null || !m.printf_format)) {
+                       if (!m.printf_format && m.sentinel != "") {
                                carg_map.set (codegen.get_param_pos (-1, true), new CCodeConstant (m.sentinel));
                        }
                } else if (itype is DelegateType) {