mail[Wesnoth-commits] r33545 - /trunk/src/ai_interface.hpp


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by dave on March 11, 2009 - 06:01:
Author: dave
Date: Wed Mar 11 05:38:10 2009
New Revision: 33545

URL: http://svn.gna.org/viewcvs/wesnoth?rev=33545&view=rev
Log:
fixed crash in formula AI when self was referenced

Modified:
    trunk/src/ai_interface.hpp

Modified: trunk/src/ai_interface.hpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/ai_interface.hpp?rev=33545&r1=33544&r2=33545&view=diff
==============================================================================
--- trunk/src/ai_interface.hpp (original)
+++ trunk/src/ai_interface.hpp Wed Mar 11 05:38:10 2009
@@ -92,7 +92,9 @@
         */
        ai_interface(info& arg) : info_(arg), last_interact_(0), 
user_interact_("ai_user_interact"),
                unit_recruited_("ai_unit_recruited"), 
unit_moved_("ai_unit_moved"),
-               enemy_attacked_("ai_enemy_attacked") {}
+               enemy_attacked_("ai_enemy_attacked") {
+               add_ref(); //this class shouldn't be reference counted.
+       }
        virtual ~ai_interface() {}
 
        /**




Related Messages


Powered by MHonArc, Updated Wed Mar 11 11:21:00 2009