Tracker: Unchecked dynamic_cast, CID 600343
This commit is contained in:
parent
bbd3b2d914
commit
d6e0dbfe30
@ -2382,11 +2382,13 @@ FindPanel::RestoreWindowState(const BNode* node)
|
|||||||
BString buffer;
|
BString buffer;
|
||||||
if (node->ReadAttrString(kAttrQueryInitialString, &buffer)
|
if (node->ReadAttrString(kAttrQueryInitialString, &buffer)
|
||||||
== B_OK) {
|
== B_OK) {
|
||||||
BTextControl* textControl = dynamic_cast<BTextControl*>
|
BTextControl* textControl = dynamic_cast<BTextControl*>(
|
||||||
(FindView("TextControl"));
|
FindView("TextControl"));
|
||||||
ASSERT(textControl);
|
|
||||||
|
|
||||||
textControl->TextView()->SetText(buffer.String());
|
ASSERT(textControl != NULL);
|
||||||
|
|
||||||
|
if (textControl != NULL)
|
||||||
|
textControl->TextView()->SetText(buffer.String());
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user