adonthell (0.3.5-5) 10_ftbfs_with_gcc-4.4.diff

Summary

 src/dialog.cc |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

    
download this patch

Patch contents

Patch backported from http://github.com/ksterker/adonthell/tree/master,
commit c620028d36510103d15efe15fed11532a4cd4a71
Index: adonthell-0.3.5/src/dialog.cc
===================================================================
--- adonthell-0.3.5.orig/src/dialog.cc	2009-09-12 09:35:25.000000000 +0400
+++ adonthell-0.3.5/src/dialog.cc	2009-09-12 09:49:58.000000000 +0400
@@ -265,7 +265,8 @@
 {
     u_int32 begin, end, len;
     PyObject *result;
-    char *tmp, *start, *mid, *str = NULL;
+    char *tmp, *mid, *str = NULL;
+    const char *start;
     character *the_player = data::the_player;
     string newstr (s); 
 
@@ -318,7 +319,7 @@
 
         // Error!
         cout << "\n*** Error, unknown macro " << start << flush;
-        start[0] = ' ';
+        newstr[newstr.length () - strlen (start)] = ' ';
     }
     
     // execute python functions