From a03220aba5e387314dd134b91ddc414b71ab9fa0 Mon Sep 17 00:00:00 2001 From: Albrecht Schlosser Date: Sun, 8 Mar 2020 12:42:30 +0100 Subject: Fix a memory leak in fluid Also fixed two typos in comments. --- fluid/Fl_Function_Type.cxx | 1 + fluid/Fl_Type.cxx | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/fluid/Fl_Function_Type.cxx b/fluid/Fl_Function_Type.cxx index 594a526a9..030c6c454 100644 --- a/fluid/Fl_Function_Type.cxx +++ b/fluid/Fl_Function_Type.cxx @@ -1322,6 +1322,7 @@ void Fl_Comment_Type::write_code1() { *e++ = eol; b = e; } + free(txt); } void Fl_Comment_Type::write_code2() {} diff --git a/fluid/Fl_Type.cxx b/fluid/Fl_Type.cxx index f8cdfa121..33cec2609 100644 --- a/fluid/Fl_Type.cxx +++ b/fluid/Fl_Type.cxx @@ -856,7 +856,7 @@ void delete_all(int selected_only) { selection_changed(0); } -// move f (and it's children) into list before g: +// move f (and its children) into list before g: // returns pointer to whatever is after f & children void Fl_Type::move_before(Fl_Type* g) { if (level != g->level) printf("move_before levels don't match! %d %d\n", @@ -917,7 +917,7 @@ void later_cb(Fl_Widget*,void*) { //////////////////////////////////////////////////////////////// -// write a widget and all it's children: +// write a widget and all its children: void Fl_Type::write() { write_indent(level); write_word(type_name()); -- cgit v1.2.3