summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2015-09-10 10:58:36 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2015-09-10 09:13:22 +0000
commitf9674ddf81f9600a74edcf59324ad99624be1348 (patch)
tree862ba95b5d90926e0c414eaef0bbb71d992d2a45 /oox
parent6d8b9aab3cea5b88b3cb56d9343500d45be8b124 (diff)
oox: work around Android build problem
Android seems to be missing std::log2(), see <https://code.google.com/p/android/issues/detail?id=68906>. Change-Id: Iab335cec0c9c5fac0908579a65ea2d434ce2f68a Reviewed-on: https://gerrit.libreoffice.org/18466 Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/ole/vbaexport.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/oox/source/ole/vbaexport.cxx b/oox/source/ole/vbaexport.cxx
index 10c0d21c06bc..b9c9676b5d38 100644
--- a/oox/source/ole/vbaexport.cxx
+++ b/oox/source/ole/vbaexport.cxx
@@ -271,7 +271,7 @@ void VBACompressionChunk::CopyTokenHelp(sal_uInt16& rLengthMask, sal_uInt16& rOf
sal_uInt16& rBitCount, sal_uInt16& rMaximumLength)
{
sal_uInt16 nDifference = mnDecompressedCurrent;
- sal_uInt16 nBitCount = std::ceil(std::log2(nDifference));
+ sal_uInt16 nBitCount = std::ceil(std::log(nDifference)/std::log(2));
rBitCount = std::max<sal_uInt16>(nBitCount, 4);
rLengthMask = 0xffff >> rBitCount;
rOffsetMask = ~rLengthMask;