vala r2290 - in trunk: . gobject



Author: juergbi
Date: Wed Jan  7 22:39:16 2009
New Revision: 2290
URL: http://svn.gnome.org/viewvc/vala?rev=2290&view=rev

Log:
2009-01-07  JÃrg Billeter  <j bitron ch>

	* gobject/valaccodebasemodule.vala:

	Fix critical when using immutable classes without copy function


Modified:
   trunk/ChangeLog
   trunk/gobject/valaccodebasemodule.vala

Modified: trunk/gobject/valaccodebasemodule.vala
==============================================================================
--- trunk/gobject/valaccodebasemodule.vala	(original)
+++ trunk/gobject/valaccodebasemodule.vala	Wed Jan  7 22:39:16 2009
@@ -1619,6 +1619,9 @@
 			} else if (cl != null && cl.is_immutable) {
 				// allow duplicates of immutable instances as for example strings
 				dup_function = type.data_type.get_dup_function ();
+				if (dup_function == null) {
+					dup_function = "";
+				}
 			} else if (type is ValueType) {
 				dup_function = type.data_type.get_dup_function ();
 				if (dup_function == null && type.nullable) {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]