summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
Diffstat (limited to 'oox')
-rw-r--r--oox/source/export/drawingml.cxx4
-rw-r--r--oox/source/helper/binaryinputstream.cxx6
2 files changed, 5 insertions, 5 deletions
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index f462fa13d32a..0a41a7ddfd4a 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -1086,7 +1086,7 @@ void DrawingML::WriteImageBrightnessContrastTransparence(uno::Reference<beans::X
}
}
-OUString DrawingML::WriteBlip( const Reference< XPropertySet >& rXPropSet, const OUString& rURL, bool bRelPathToMedia, const Graphic *pGraphic )
+OUString DrawingML::WriteBlip( const Reference< XPropertySet >& rXPropSet, const OUString& rURL, bool bRelPathToMedia )
{
OUString sRelId;
BitmapChecksum nChecksum = 0;
@@ -1101,7 +1101,7 @@ OUString DrawingML::WriteBlip( const Reference< XPropertySet >& rXPropSet, const
}
if (sRelId.isEmpty())
{
- sRelId = pGraphic ? WriteImage( *pGraphic, bRelPathToMedia ) : WriteImage( rURL, bRelPathToMedia );
+ sRelId = WriteImage( rURL, bRelPathToMedia );
if (!rURL.isEmpty() && mpTextExport)
mpTextExport->CacheRelId(nChecksum, sRelId);
}
diff --git a/oox/source/helper/binaryinputstream.cxx b/oox/source/helper/binaryinputstream.cxx
index 6eb5a6ed75c5..bc060027e7cf 100644
--- a/oox/source/helper/binaryinputstream.cxx
+++ b/oox/source/helper/binaryinputstream.cxx
@@ -74,7 +74,7 @@ OUString BinaryInputStream::readCharArrayUC( sal_Int32 nChars, rtl_TextEncoding
return OStringToOUString( readCharArray( nChars ), eTextEnc );
}
-OUString BinaryInputStream::readUnicodeArray( sal_Int32 nChars, bool bAllowNulChars )
+OUString BinaryInputStream::readUnicodeArray( sal_Int32 nChars )
{
if( nChars <= 0 )
return OUString();
@@ -85,8 +85,8 @@ OUString BinaryInputStream::readUnicodeArray( sal_Int32 nChars, bool bAllowNulCh
return OUString();
aBuffer.resize( static_cast< size_t >( nCharsRead ) );
- if( !bAllowNulChars )
- ::std::replace( aBuffer.begin(), aBuffer.begin() + nCharsRead, '\0', '?' );
+ // don't allow nul chars
+ ::std::replace( aBuffer.begin(), aBuffer.begin() + nCharsRead, '\0', '?' );
OUStringBuffer aStringBuffer;
aStringBuffer.ensureCapacity( nCharsRead );