This is an automated email from the ASF dual-hosted git repository. jimjag pushed a commit to branch AOO42X in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit 1a61f9a5d8c18413d7c8e8c30f2f50ba7a43a929 Author: Damjan Jovanovic <[email protected]> AuthorDate: Fri Jan 3 07:01:21 2025 +0200 Change the return type of Get10ThSec() to clock_t, so it works regardless of the size of the integer type. Patch by: me (cherry picked from commit 448dc86220cf9531c9c48d1efc4e906d246b1899) --- main/sfx2/source/bastyp/progress.cxx | 2 +- main/sfx2/source/view/sfxbasecontroller.cxx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/main/sfx2/source/bastyp/progress.cxx b/main/sfx2/source/bastyp/progress.cxx index efacc2cfd1..f360c0574a 100644 --- a/main/sfx2/source/bastyp/progress.cxx +++ b/main/sfx2/source/bastyp/progress.cxx @@ -110,7 +110,7 @@ struct SfxProgress_Impl #define aTypeLibInfo aProgressTypeLibImpl //======================================================================== -extern sal_uIntPtr Get10ThSec(); +extern clock_t Get10ThSec(); // ----------------------------------------------------------------------- diff --git a/main/sfx2/source/view/sfxbasecontroller.cxx b/main/sfx2/source/view/sfxbasecontroller.cxx index bb174eeeb6..015084586b 100644 --- a/main/sfx2/source/view/sfxbasecontroller.cxx +++ b/main/sfx2/source/view/sfxbasecontroller.cxx @@ -220,9 +220,9 @@ sal_Bool SupportsCommandGroup( sal_Int16 nCommandGroup ) return sal_False; } -sal_uInt32 Get10ThSec() +clock_t Get10ThSec() { - sal_uInt32 n10Ticks = 10 * (sal_uInt32)clock(); + clock_t n10Ticks = 10 * clock(); return n10Ticks / CLOCKS_PER_SEC; } @@ -246,7 +246,7 @@ friend class SfxBaseController; SfxWorkWindow* pWorkWindow; sal_Int32 _nRange; sal_Int32 _nValue; - long _nStartTime; + clock_t _nStartTime; public: SfxStatusIndicator(SfxBaseController* pController, SfxWorkWindow* pWork) : xOwner( pController )
