summaryrefslogtreecommitdiff
path: root/cppuhelper
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-06-14 11:31:15 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-06-15 08:24:33 +0200
commitec8c98f59869bee0e327d32f39480a0e4b1330bc (patch)
treeee68d29cd51c60a8a939fd454955410e66e3b66c /cppuhelper
parent11503e99be09b4e8faa465559fbdacb06e8896cc (diff)
use more SAL_N_ELEMENTS part 3
Change-Id: I82e366fefd2e31928b99840fe76649cc3521e623 Reviewed-on: https://gerrit.libreoffice.org/38789 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cppuhelper')
-rw-r--r--cppuhelper/source/bootstrap.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/cppuhelper/source/bootstrap.cxx b/cppuhelper/source/bootstrap.cxx
index 0d64c56e9e62..55a0d244b724 100644
--- a/cppuhelper/source/bootstrap.cxx
+++ b/cppuhelper/source/bootstrap.cxx
@@ -42,8 +42,6 @@
#include "macro_expander.hxx"
-#define ARLEN(x) sizeof (x) / sizeof *(x)
-
using namespace ::osl;
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -138,7 +136,7 @@ Reference< XComponentContext > SAL_CALL bootstrap()
if ( hPool == nullptr )
throw BootstrapException( "cannot create random pool!" );
sal_uInt8 bytes[ 16 ];
- if ( rtl_random_getBytes( hPool, bytes, ARLEN( bytes ) )
+ if ( rtl_random_getBytes( hPool, bytes, SAL_N_ELEMENTS( bytes ) )
!= rtl_Random_E_None )
throw BootstrapException( "random pool error!" );
rtl_random_destroyPool( hPool );
@@ -167,7 +165,7 @@ Reference< XComponentContext > SAL_CALL bootstrap()
// start office process
oslProcess hProcess = nullptr;
oslProcessError rc = osl_executeProcess(
- OUString(path + "soffice").pData, ar_args, ARLEN( ar_args ),
+ OUString(path + "soffice").pData, ar_args, SAL_N_ELEMENTS( ar_args ),
osl_Process_DETACHED,
sec.getHandle(),
nullptr, // => current working dir