On Thu, 28 Nov 2002, Angus Leeming wrote:

> Here's the patch. It works fine.

It's looks okay to me too.  Although a little extra whitespace in the
substituted code below would be nice (hint: ...str(), 1)

 # For all lines containing "fl_add" and a string containing |
@@ -89,12 +89,12 @@ s/\(        fdui->form\)\(.*bgn_form.*\)/\1\2\
 #        fdui->counter_zoom = obj = fl_add_counter(...,"Zoom %|#Z");
 # becomes
 #        c_str = _("Zoom %|#Z");
-#        fdui->counter_zoom = obj = fl_add_counter(...,idex(c_str));
-#        fl_set_button_shortcut(obj,scex(c_str),1);
+#        fdui->counter_zoom = obj = fl_add_counter(...,idex(c_str).c_str());
+#        fl_set_button_shortcut(obj,scex(c_str).c_str(),1);

 /fl_add.*".*[|].*"/s/fdui\(.*\)"\(.*\)".*/c_str = _("\2");\
-       fdui\1idex(c_str));\
-       fl_set_button_shortcut(obj,scex(c_str),1);/
+       fdui\1idex(c_str).c_str());\
+       fl_set_button_shortcut(obj,scex(c_str).c_str(),1);/

> I still can't believe that this was really a memory leak (simply because I'm
> amazed it hasn't been picked up before), so would like confirmation that I've
> done the right thing.

This leak has been known and ignored for ages.

> Ok to apply or just plain unnecessary?

It's neater and doesn't hurt anything.

Allan. (ARRae)



Reply via email to