From 346feb80d43df0b4fd48d9f00cc6da152b0111af Mon Sep 17 00:00:00 2001 From: Thilo Graf Date: Sun, 10 Nov 2013 21:45:02 +0100 Subject: [PATCH] CComponentsExtTextForm: remove check for empty strings This check causes possible segfault and check is already in ccx_text_obj. Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/05ce02327882aba9e959e1f62b50a52a901f785f Author: Thilo Graf Date: 2013-11-10 (Sun, 10 Nov 2013) --- src/gui/components/cc_frm_ext_text.cpp | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/gui/components/cc_frm_ext_text.cpp b/src/gui/components/cc_frm_ext_text.cpp index 7120040d5..149786e28 100644 --- a/src/gui/components/cc_frm_ext_text.cpp +++ b/src/gui/components/cc_frm_ext_text.cpp @@ -111,14 +111,6 @@ void CComponentsExtTextForm::initVarExtTextForm(const int x_pos, const int y_pos void CComponentsExtTextForm::initLabel() { - //init label object only if text available - if (ccx_label_text.empty()) { - if (ccx_label_obj) - delete ccx_label_obj; - ccx_label_obj = NULL; - return; - } - //initialize label object if (ccx_label_obj == NULL){ ccx_label_obj = new CComponentsLabel(); @@ -141,14 +133,6 @@ void CComponentsExtTextForm::initLabel() void CComponentsExtTextForm::initText() { - //init text object only if text available - if (ccx_text.empty()) { - if (ccx_text_obj) - delete ccx_text_obj; - ccx_text_obj = NULL; - return; - } - //initialize text object if (ccx_text_obj == NULL){ ccx_text_obj = new CComponentsLabel();