Kaydet (Commit) 369d1e42 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1325246 Unchecked dynamic_cast

Change-Id: Ifa8f9ce23c9c737d7bed9e24c9c32641d915ac76
üst 6f7e93b9
...@@ -230,14 +230,12 @@ public: ...@@ -230,14 +230,12 @@ public:
{ {
bool bRet = false; bool bRet = false;
SvXMLImportContext *pContext = &xContext; SvXMLImportContext *pContext = &xContext;
if( 0 != dynamic_cast<const XMLTextFrameContext*>(pContext) ) if (XMLTextFrameContext *pFrameContext = dynamic_cast<XMLTextFrameContext*>(pContext))
bRet = css::text::TextContentAnchorType_AT_CHARACTER == bRet = css::text::TextContentAnchorType_AT_CHARACTER ==
dynamic_cast<const XMLTextFrameContext*>( pContext ) pFrameContext->GetAnchorType();
->GetAnchorType(); else if (XMLTextFrameHyperlinkContext *pLinkContext = dynamic_cast<XMLTextFrameHyperlinkContext*>(pContext))
else if( 0 != dynamic_cast<const XMLTextFrameHyperlinkContext*>( pContext) )
bRet = css::text::TextContentAnchorType_AT_CHARACTER == bRet = css::text::TextContentAnchorType_AT_CHARACTER ==
dynamic_cast<const XMLTextFrameHyperlinkContext*>( pContext ) pLinkContext->GetAnchorType();
->GetAnchorType();
return bRet; return bRet;
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment