From: Jürg Billeter Date: Sun, 13 Sep 2009 16:09:58 +0000 (+0200) Subject: Fix crash with virtual async methods X-Git-Tag: 0.7.6~109 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7f913d96ae72c080bfa5a2d6d90e744db37b53e4;p=thirdparty%2Fvala.git Fix crash with virtual async methods --- diff --git a/codegen/valaccodemethodmodule.vala b/codegen/valaccodemethodmodule.vala index b38f4c140..281c44acf 100644 --- a/codegen/valaccodemethodmodule.vala +++ b/codegen/valaccodemethodmodule.vala @@ -845,7 +845,9 @@ internal class Vala.CCodeMethodModule : CCodeStructModule { public void generate_vfunc (Method m, DataType return_type, Map cparam_map, Map carg_map, string suffix = "", int direction = 3) { var vfunc = new CCodeFunction (m.get_cname () + suffix); - vfunc.line = function.line; + if (function != null) { + vfunc.line = function.line; + } var vblock = new CCodeBlock ();