summaryrefslogtreecommitdiff
path: root/jvmfwk/plugins
diff options
context:
space:
mode:
authorChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-07-11 02:03:01 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-07-11 14:53:01 +0000
commit1b4d27a3badddd2648c3f02cd234ca74c5a40e6b (patch)
treed8d5bac23a72ab59f5a63e63de5b965919c3b0c6 /jvmfwk/plugins
parent238575424341dedaef9713fcdb988ed39ccbf82c (diff)
tdf#92483 fix initializing JRE on Win 64bit (load java's msvcr100.dll)
problem is that the offsets/sizes are of different type than ptrdiff_t, and when using without casting, the resulting address is way off... Change-Id: I7b1cdd611c8c4b317cd33ca8fbbda2e7e8f5f4fc Reviewed-on: https://gerrit.libreoffice.org/16938 Reviewed-by: David Ostrovsky <david@ostrovsky.org> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'jvmfwk/plugins')
-rw-r--r--jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
index a19b26a18c61..c7a273c82ae9 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx
@@ -588,7 +588,7 @@ static void do_msvcr_magic(rtl_uString *jvm_dll)
if (sections->VirtualAddress <= importsVA &&
importsVA < sections->VirtualAddress + sections->SizeOfRawData)
{
- VAtoPhys = sections->PointerToRawData - sections->VirtualAddress;
+ VAtoPhys = static_cast<size_t>(sections->PointerToRawData) - static_cast<size_t>(sections->VirtualAddress);
break;
}
++sections;