Kaydet (Commit) a9269e41 authored tarafından Arnaud Versini's avatar Arnaud Versini Kaydeden (comit) Caolán McNamara

VCL: I18NStatus::setStatusText shouldn't depend on aStr[len] == 0

Change-Id: Ifa0770eb24df4ae4c7c058b980545a9094bbdf50
Reviewed-on: https://gerrit.libreoffice.org/6461Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 47690627
......@@ -587,7 +587,7 @@ void I18NStatus::setStatusText( const OUString& rText )
/*
* #93614# convert fullwidth ASCII forms to ascii
*/
int nChars = rText.getLength()+1;
int nChars = rText.getLength();
sal_Unicode* pBuffer = (sal_Unicode*)alloca( nChars*sizeof( sal_Unicode ) );
for( int i = 0; i < nChars; i++ )
{
......@@ -596,7 +596,7 @@ void I18NStatus::setStatusText( const OUString& rText )
else
pBuffer[i] = rText[i];
}
OUString aText( pBuffer );
OUString aText( pBuffer, nChars );
m_pStatusWindow->setText( aText );
m_pStatusWindow->setPosition( m_pParent );
......
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