diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-04-07 20:54:55 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-04-08 13:18:41 +0200 |
commit | 36e0e88b28e818faf25b8e32cc8c4dc444b8a0be (patch) | |
tree | b7b5c8e13b6e05f871b01a3d0bf68c1d1329ef12 /basic/source | |
parent | cf5bbe3fce4a250ab25998053965bdc604c6114e (diff) |
use more subView when converting to Int32
Change-Id: I54e3ddf79ba793fd4328bf8bda7f949b65349651
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132693
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basic/source')
-rw-r--r-- | basic/source/runtime/dllmgr-x64.cxx | 2 | ||||
-rw-r--r-- | basic/source/runtime/dllmgr-x86.cxx | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/basic/source/runtime/dllmgr-x64.cxx b/basic/source/runtime/dllmgr-x64.cxx index b2ddbb890da1..15226cc3fb3c 100644 --- a/basic/source/runtime/dllmgr-x64.cxx +++ b/basic/source/runtime/dllmgr-x64.cxx @@ -608,7 +608,7 @@ ErrCode getProcData(HMODULE handle, OUString const & name, ProcData * proc) { assert(proc != nullptr); if (name.getLength() != 0 && name[0] == '@') { //TODO: "@" vs. "#"??? - sal_Int32 n = name.copy(1).toInt32(); //TODO: handle bad input + sal_Int32 n = comphelper::string::toInt32(name.subView(1)); //TODO: handle bad input if (n <= 0 || n > 0xFFFF) { return ERRCODE_BASIC_BAD_ARGUMENT; //TODO: more specific errcode? } diff --git a/basic/source/runtime/dllmgr-x86.cxx b/basic/source/runtime/dllmgr-x86.cxx index 93e5c2bf533f..3433282c22ec 100644 --- a/basic/source/runtime/dllmgr-x86.cxx +++ b/basic/source/runtime/dllmgr-x86.cxx @@ -584,7 +584,7 @@ ErrCode getProcData(HMODULE handle, OUString const & name, ProcData * proc) { assert(proc != 0); if ( !name.isEmpty() && name[0] == '@' ) { //TODO: "@" vs. "#"??? - sal_Int32 n = name.copy(1).toInt32(); //TODO: handle bad input + sal_Int32 n = comphelper::string::toInt32(name.subView(1)); //TODO: handle bad input if (n <= 0 || n > 0xFFFF) { return ERRCODE_BASIC_BAD_ARGUMENT; //TODO: more specific errcode? } |