summaryrefslogtreecommitdiff
path: root/cppuhelper
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-03-09 17:38:28 +0100
committerStephan Bergmann <sbergman@redhat.com>2016-03-10 18:32:03 +0100
commit132b4e91bc6a4d4cb545f62475e3156cb22c4e6d (patch)
tree9001d66764e9929f6f7125d4a5dac3ee4ce292c3 /cppuhelper
parent9128faccd3e745a1087755c3086ea012109980b9 (diff)
Avoid reserved identifiers (use unnamed namespace, just in case)
Change-Id: I3e34368a674e9f128a32604c82181b1b99632c37
Diffstat (limited to 'cppuhelper')
-rw-r--r--cppuhelper/source/access_control.cxx17
1 files changed, 10 insertions, 7 deletions
diff --git a/cppuhelper/source/access_control.cxx b/cppuhelper/source/access_control.cxx
index 7d206677d281..2ed773596370 100644
--- a/cppuhelper/source/access_control.cxx
+++ b/cppuhelper/source/access_control.cxx
@@ -69,11 +69,13 @@ AccessControl::AccessControl( AccessControl const & ac )
}
}
+namespace {
+
#ifdef SAL_W32
#pragma pack(push, 8)
#endif
// binary comp. to all Permission structs
- struct __permission
+ struct permission
{
rtl_uString * m_str1;
rtl_uString * m_str2;
@@ -82,12 +84,11 @@ AccessControl::AccessControl( AccessControl const & ac )
#pragma pack(pop)
#endif
-
-inline void __checkPermission(
+inline void checkPermission(
Reference< security::XAccessController > const & xController,
Type const & type, rtl_uString * str1, rtl_uString * str2 )
{
- __permission perm;
+ permission perm;
perm.m_str1 = str1;
perm.m_str2 = str2;
@@ -98,10 +99,12 @@ inline void __checkPermission(
xController->checkPermission( * static_cast< Any * >( &a ) );
}
+}
+
void AccessControl::checkRuntimePermission(
OUString const & name )
{
- __checkPermission(
+ checkPermission(
m_xController,
cppu::UnoType<security::RuntimePermission>::get(), name.pData, nullptr );
}
@@ -110,7 +113,7 @@ void AccessControl::checkFilePermission(
OUString const & url,
OUString const & actions )
{
- __checkPermission(
+ checkPermission(
m_xController,
cppu::UnoType<io::FilePermission>::get(), url.pData, actions.pData );
}
@@ -119,7 +122,7 @@ void AccessControl::checkSocketPermission(
OUString const & host,
OUString const & actions )
{
- __checkPermission(
+ checkPermission(
m_xController,
cppu::UnoType<connection::SocketPermission>::get(), host.pData, actions.pData );
}