diff options
author | DS <vorunbekannt75@web.de> | 2020-03-10 20:32:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-10 20:32:38 +0100 |
commit | b42493fb4c40611020c9ded9b7af5b96dc4148bd (patch) | |
tree | b61a502308b865fa3c1160129339aea9df65a005 /src/gui/guiFormSpecMenu.cpp | |
parent | 7a7bfdca7c2dcbfe40467f64544112551abd7316 (diff) | |
download | minetest-b42493fb4c40611020c9ded9b7af5b96dc4148bd.tar.gz minetest-b42493fb4c40611020c9ded9b7af5b96dc4148bd.tar.bz2 minetest-b42493fb4c40611020c9ded9b7af5b96dc4148bd.zip |
Fix memory leak in GUIHyperText (#9489)
Diffstat (limited to 'src/gui/guiFormSpecMenu.cpp')
-rw-r--r-- | src/gui/guiFormSpecMenu.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/guiFormSpecMenu.cpp b/src/gui/guiFormSpecMenu.cpp index e1bb58f17..45eb0d17c 100644 --- a/src/gui/guiFormSpecMenu.cpp +++ b/src/gui/guiFormSpecMenu.cpp @@ -1654,8 +1654,9 @@ void GUIFormSpecMenu::parseHyperText(parserData *data, const std::string &elemen ); spec.ftype = f_Unknown; - new GUIHyperText( - spec.flabel.c_str(), Environment, this, spec.fid, rect, m_client, m_tsrc); + GUIHyperText *e = new GUIHyperText(spec.flabel.c_str(), Environment, this, + spec.fid, rect, m_client, m_tsrc); + e->drop(); m_fields.push_back(spec); } |