Skip to content

Commit

Permalink
Fixed missing image release as described in STR #2840.
Browse files Browse the repository at this point in the history
Thanks to OP (Nikego) and Matt!


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10888 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
  • Loading branch information
Albrecht Schlosser committed Nov 7, 2015
1 parent da6dff2 commit 144c656
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGES
Expand Up @@ -54,6 +54,7 @@ CHANGES IN FLTK 1.3.4 RELEASED: ??? ?? ????

Bug fixes

- Fixed missing image release in fluid (STR #2840).
- Fixed out-of-bounds memory access in fluid (STR #3263).
- fluid doesn't output trailing white space in .fl files after
some statements anymore (STR #3239).
Expand Down
10 changes: 8 additions & 2 deletions fluid/Fl_Widget_Type.cxx
Expand Up @@ -215,8 +215,14 @@ Fl_Widget_Type::~Fl_Widget_Type() {
}
if (subclass_) free((void*)subclass_);
if (tooltip_) free((void*)tooltip_);
if (image_name_) free((void*)image_name_);
if (inactive_name_) free((void*)inactive_name_);
if (image_name_) {
free((void*)image_name_);
if (image) image->decrement();
}
if (inactive_name_) {
free((void*)inactive_name_);
if (inactive) inactive->decrement();
}
for (int n=0; n<NUM_EXTRA_CODE; n++) {
if (extra_code_[n]) free((void*) extra_code_[n]);
}
Expand Down

0 comments on commit 144c656

Please sign in to comment.