bugfix: free the shape-corners on the last used 'Shape'
the global 's_corners' vector was still used on an application shutdown (including ctrl-c SIGINT). depending on when 's_corners' was created on the stack this could lead to an exception ('pure virtual called') while trying to free the 'FbPixmaps' without having a valid 'FbTk::Application::instance()' left.
This commit is contained in:
parent
36893ac7f9
commit
75b9a4ed72
1 changed files with 1 additions and 1 deletions
|
@ -134,7 +134,7 @@ void initCorners(FbWindow& win) {
|
||||||
|
|
||||||
void cleanCorners() {
|
void cleanCorners() {
|
||||||
|
|
||||||
if (nr_shapes == 0) {
|
if (nr_shapes == 1) {
|
||||||
s_corners.clear();
|
s_corners.clear();
|
||||||
} else {
|
} else {
|
||||||
nr_shapes--; // refcounting
|
nr_shapes--; // refcounting
|
||||||
|
|
Loading…
Reference in a new issue