glibmm r720 - in trunk: . tests/glibmm_nodetree



Author: murrayc
Date: Tue Aug 26 13:38:29 2008
New Revision: 720
URL: http://svn.gnome.org/viewvc/glibmm?rev=720&view=rev

Log:
2008-08-26  Murray Cumming  <murrayc murrayc com>

* tests/glibmm_nodetree/main.cc: Actually use the copy constructor (or operator=), 
instead of just copying the pointer.

Modified:
   trunk/ChangeLog
   trunk/tests/glibmm_nodetree/main.cc

Modified: trunk/tests/glibmm_nodetree/main.cc
==============================================================================
--- trunk/tests/glibmm_nodetree/main.cc	(original)
+++ trunk/tests/glibmm_nodetree/main.cc	Tue Aug 26 13:38:29 2008
@@ -119,7 +119,7 @@
   tstring.clear();
 
 
-  node = root; //A deep copy.
+  node = new type_nodetree_string(*root); //A deep copy.
   g_assert(root->node_count(type_nodetree_string::TRAVERSE_ALL) == node->node_count(type_nodetree_string::TRAVERSE_ALL));
   g_assert(root->get_max_height() == node->get_max_height());
   root->traverse(sigc::bind(sigc::ptr_fun(node_build_string), sigc::ref(tstring)), Glib::TRAVERSE_IN_ORDER, type_nodetree_string::TRAVERSE_ALL, -1);



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