Kaydet (Commit) 0c1e9111 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#704104 Unchecked return value

Change-Id: I4a2c49befe4baea10e36e0d612371fe8c91db401
üst 98a19ed0
......@@ -425,13 +425,18 @@ PrinterGfx::DrawText (
);
}
void PrinterGfx::drawVerticalizedText(
bool PrinterGfx::drawVerticalizedText(
const Point& rPoint,
const sal_Unicode* pStr,
sal_Int16 nLen,
const sal_Int32* pDeltaArray
)
{
PrintFontManager &rMgr = PrintFontManager::get();
PrintFontInfo aInfo;
if (!rMgr.getFontInfo(mnFontID, aInfo))
return false;
sal_Int32* pDelta = (sal_Int32*)alloca( nLen * sizeof(sal_Int32) );
int nTextScale = maVirtualStatus.mnTextWidth ? maVirtualStatus.mnTextWidth : maVirtualStatus.mnTextHeight;
......@@ -441,10 +446,6 @@ void PrinterGfx::drawVerticalizedText(
double fSin = sin( -2.0*M_PI*nNormalAngle/3600 );
double fCos = cos( -2.0*M_PI*nNormalAngle/3600 );
PrintFontManager &rMgr = PrintFontManager::get();
PrintFontInfo aInfo;
rMgr.getFontInfo( mnFontID, aInfo );
bool* pGsubFlags = (bool*)alloca( nLen * sizeof(bool) );
rMgr.hasVerticalSubstitutions( mnFontID, pStr, nLen, pGsubFlags );
......@@ -518,6 +519,7 @@ void PrinterGfx::drawVerticalizedText(
nLastPos = i;
}
mnTextAngle = nNormalAngle;
return true;
}
void
......
......@@ -304,7 +304,7 @@ public:
void writeResources( osl::File* pFile, std::list< OString >& rSuppliedFonts );
PrintFontManager& GetFontMgr () { return mrFontMgr; }
void drawVerticalizedText (const Point& rPoint,
bool drawVerticalizedText (const Point& rPoint,
const sal_Unicode* pStr,
sal_Int16 nLen,
const sal_Int32* pDeltaArray );
......
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