summaryrefslogtreecommitdiff
path: root/mysqlc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-11-10 10:19:59 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-11-10 10:31:32 +0100
commit1ddbbfdda834965c861a67e275ab58ff4d1f0bf9 (patch)
tree70ebffcd5fbf2a818ba313af94de68ac2adf36ca /mysqlc
parent822a0b7046d8f0a8325ad158ea6756d33846c83e (diff)
loplugin:nullptr (automatic rewrite)
Change-Id: Ie77375d781164232ea0cd94c3d2a5d027c49669e
Diffstat (limited to 'mysqlc')
-rw-r--r--mysqlc/source/mysqlc_connection.cxx2
-rw-r--r--mysqlc/source/mysqlc_databasemetadata.cxx4
-rw-r--r--mysqlc/source/mysqlc_driver.cxx8
-rw-r--r--mysqlc/source/mysqlc_general.hxx4
-rw-r--r--mysqlc/source/mysqlc_resultset.cxx18
-rw-r--r--mysqlc/source/mysqlc_services.cxx4
-rw-r--r--mysqlc/source/mysqlc_statement.cxx4
-rw-r--r--mysqlc/source/mysqlc_subcomponent.hxx4
-rw-r--r--mysqlc/source/mysqlc_types.cxx2
9 files changed, 25 insertions, 25 deletions
diff --git a/mysqlc/source/mysqlc_connection.cxx b/mysqlc/source/mysqlc_connection.cxx
index e0b0425871ce..5c3fd7c2cb59 100644
--- a/mysqlc/source/mysqlc_connection.cxx
+++ b/mysqlc/source/mysqlc_connection.cxx
@@ -63,7 +63,7 @@ using ::osl::MutexGuard;
OConnection::OConnection(MysqlCDriver& _rDriver, sql::Driver * _cppDriver)
:OMetaConnection_BASE(m_aMutex)
,OSubComponent<OConnection, OConnection_BASE>(static_cast<cppu::OWeakObject*>(&_rDriver), this)
- ,m_xMetaData(NULL)
+ ,m_xMetaData(nullptr)
,m_rDriver(_rDriver)
,cppDriver(_cppDriver)
,m_bClosed(false)
diff --git a/mysqlc/source/mysqlc_databasemetadata.cxx b/mysqlc/source/mysqlc_databasemetadata.cxx
index 39abb7f0829e..f7a49cfbe79c 100644
--- a/mysqlc/source/mysqlc_databasemetadata.cxx
+++ b/mysqlc/source/mysqlc_databasemetadata.cxx
@@ -1351,7 +1351,7 @@ Reference< XResultSet > SAL_CALL ODatabaseMetaData::getProcedureColumns(
{
OSL_TRACE("ODatabaseMetaData::getProcedureColumns");
// Currently there is no information available
- return NULL;
+ return nullptr;
}
Reference< XResultSet > SAL_CALL ODatabaseMetaData::getProcedures(
@@ -1715,7 +1715,7 @@ Reference< XResultSet > SAL_CALL ODatabaseMetaData::getUDTs(
{
OSL_TRACE("ODatabaseMetaData::getUDTs");
mysqlc_sdbc_driver::throwFeatureNotImplementedException("ODatabaseMetaData::getUDTs", *this);
- return NULL;
+ return nullptr;
}
/*
diff --git a/mysqlc/source/mysqlc_driver.cxx b/mysqlc/source/mysqlc_driver.cxx
index 399d6228eecb..3a31685d9c2e 100644
--- a/mysqlc/source/mysqlc_driver.cxx
+++ b/mysqlc/source/mysqlc_driver.cxx
@@ -45,12 +45,12 @@ MysqlCDriver::MysqlCDriver(const Reference< XMultiServiceFactory >& _rxFactory)
: ODriver_BASE(m_aMutex)
,m_xFactory(_rxFactory)
#ifndef SYSTEM_MYSQL_CPPCONN
- ,m_hCppConnModule( NULL )
+ ,m_hCppConnModule( nullptr )
,m_bAttemptedLoadCppConn( false )
#endif
{
OSL_TRACE("MysqlCDriver::MysqlCDriver");
- cppDriver = NULL;
+ cppDriver = nullptr;
}
void MysqlCDriver::disposing()
@@ -198,7 +198,7 @@ Reference< XConnection > SAL_CALL MysqlCDriver::connect(const rtl::OUString& url
OSL_TRACE("MysqlCDriver::connect");
if (!acceptsURL(url)) {
- return NULL;
+ return nullptr;
}
if ( !cppDriver )
@@ -297,7 +297,7 @@ void release(oslInterlockedCount& _refCount,
{
::osl::MutexGuard aGuard(rBHelper.rMutex);
xParent = _xInterface;
- _xInterface = NULL;
+ _xInterface = nullptr;
}
// First dispose
diff --git a/mysqlc/source/mysqlc_general.hxx b/mysqlc/source/mysqlc_general.hxx
index 83318944a047..d0a9c27de440 100644
--- a/mysqlc/source/mysqlc_general.hxx
+++ b/mysqlc/source/mysqlc_general.hxx
@@ -34,14 +34,14 @@ namespace mysqlc_sdbc_driver
void throwFeatureNotImplementedException(
const sal_Char* _pAsciiFeatureName,
const css::uno::Reference< css::uno::XInterface >& _rxContext,
- const css::uno::Any* _pNextException = NULL
+ const css::uno::Any* _pNextException = nullptr
)
throw (css::sdbc::SQLException);
void throwInvalidArgumentException(
const sal_Char* _pAsciiFeatureName,
const css::uno::Reference< css::uno::XInterface >& _rxContext,
- const css::uno::Any* _pNextException = NULL
+ const css::uno::Any* _pNextException = nullptr
)
throw (css::sdbc::SQLException);
diff --git a/mysqlc/source/mysqlc_resultset.cxx b/mysqlc/source/mysqlc_resultset.cxx
index c371bbced9c1..6f8236e5aba6 100644
--- a/mysqlc/source/mysqlc_resultset.cxx
+++ b/mysqlc/source/mysqlc_resultset.cxx
@@ -76,7 +76,7 @@ OResultSet::OResultSet(OCommonStatement * pStmt, sql::ResultSet * result, rtl_Te
: OResultSet_BASE(m_aMutex)
,OPropertySetHelper(OResultSet_BASE::rBHelper)
,m_aStatement(static_cast<OWeakObject*>(pStmt))
- ,m_xMetaData(NULL)
+ ,m_xMetaData(nullptr)
,m_result(result)
,fieldCount( 0 )
,m_encoding( _encoding )
@@ -102,8 +102,8 @@ void OResultSet::disposing()
MutexGuard aGuard(m_aMutex);
- m_aStatement = NULL;
- m_xMetaData = NULL;
+ m_aStatement = nullptr;
+ m_xMetaData = nullptr;
}
Any SAL_CALL OResultSet::queryInterface(const Type & rType)
@@ -165,7 +165,7 @@ Reference< XInputStream > SAL_CALL OResultSet::getBinaryStream(sal_Int32 column)
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getBinaryStream", *this);
- return NULL;
+ return nullptr;
}
Reference< XInputStream > SAL_CALL OResultSet::getCharacterStream(sal_Int32 column)
@@ -177,7 +177,7 @@ Reference< XInputStream > SAL_CALL OResultSet::getCharacterStream(sal_Int32 colu
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getCharacterStream", *this);
- return NULL;
+ return nullptr;
}
sal_Bool SAL_CALL OResultSet::getBoolean(sal_Int32 column)
@@ -370,7 +370,7 @@ Reference< XArray > SAL_CALL OResultSet::getArray(sal_Int32 column)
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getArray", *this);
- return NULL;
+ return nullptr;
}
Reference< XClob > SAL_CALL OResultSet::getClob(sal_Int32 column)
@@ -382,7 +382,7 @@ Reference< XClob > SAL_CALL OResultSet::getClob(sal_Int32 column)
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getClob", *this);
- return NULL;
+ return nullptr;
}
Reference< XBlob > SAL_CALL OResultSet::getBlob(sal_Int32 column)
@@ -394,7 +394,7 @@ Reference< XBlob > SAL_CALL OResultSet::getBlob(sal_Int32 column)
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getBlob", *this);
- return NULL;
+ return nullptr;
}
Reference< XRef > SAL_CALL OResultSet::getRef(sal_Int32 column)
@@ -406,7 +406,7 @@ Reference< XRef > SAL_CALL OResultSet::getRef(sal_Int32 column)
checkColumnIndex(column);
mysqlc_sdbc_driver::throwFeatureNotImplementedException("OResultSet::getRef", *this);
- return NULL;
+ return nullptr;
}
Any SAL_CALL OResultSet::getObject(sal_Int32 column, const Reference< XNameAccess >& /* typeMap */)
diff --git a/mysqlc/source/mysqlc_services.cxx b/mysqlc/source/mysqlc_services.cxx
index 1671b87772c3..66ae887cda83 100644
--- a/mysqlc/source/mysqlc_services.cxx
+++ b/mysqlc/source/mysqlc_services.cxx
@@ -63,7 +63,7 @@ struct ProviderRequest
{
if (!xRet.is() && (Implname == sImplementationName)) {
try {
- xRet = creator( xServiceManager, sImplementationName,Factory, Services,0);
+ xRet = creator( xServiceManager, sImplementationName,Factory, Services,nullptr);
} catch (...) {
}
}
@@ -78,7 +78,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
void * pServiceManager,
void * /* pRegistryKey */)
{
- void* pRet = 0;
+ void* pRet = nullptr;
if (pServiceManager) {
ProviderRequest aReq(pServiceManager,pImplementationName);
diff --git a/mysqlc/source/mysqlc_statement.cxx b/mysqlc/source/mysqlc_statement.cxx
index 56a9859073c5..859f7a929a82 100644
--- a/mysqlc/source/mysqlc_statement.cxx
+++ b/mysqlc/source/mysqlc_statement.cxx
@@ -75,7 +75,7 @@ void OCommonStatement::disposeResultSet()
OSL_TRACE("OCommonStatement::disposeResultSet");
// free the cursor if alive
delete cppStatement;
- cppStatement = NULL;
+ cppStatement = nullptr;
}
void OCommonStatement::disposing()
@@ -87,7 +87,7 @@ void OCommonStatement::disposing()
if (m_pConnection) {
m_pConnection->release();
- m_pConnection = NULL;
+ m_pConnection = nullptr;
}
delete cppStatement;
diff --git a/mysqlc/source/mysqlc_subcomponent.hxx b/mysqlc/source/mysqlc_subcomponent.hxx
index e052bf85490f..92bb81564108 100644
--- a/mysqlc/source/mysqlc_subcomponent.hxx
+++ b/mysqlc/source/mysqlc_subcomponent.hxx
@@ -108,7 +108,7 @@ namespace connectivity
if (!--s_nRefCount)
{
delete s_pProps;
- s_pProps = NULL;
+ s_pProps = nullptr;
}
}
@@ -134,7 +134,7 @@ namespace connectivity
sal_Int32 OPropertyArrayUsageHelper< TYPE >::s_nRefCount = 0;
template<class TYPE>
- ::cppu::IPropertyArrayHelper* OPropertyArrayUsageHelper< TYPE >::s_pProps = NULL;
+ ::cppu::IPropertyArrayHelper* OPropertyArrayUsageHelper< TYPE >::s_pProps = nullptr;
template<class TYPE>
::osl::Mutex OPropertyArrayUsageHelper< TYPE >::s_aMutex;
diff --git a/mysqlc/source/mysqlc_types.cxx b/mysqlc/source/mysqlc_types.cxx
index 812c817c9a5c..6c2849a7837f 100644
--- a/mysqlc/source/mysqlc_types.cxx
+++ b/mysqlc/source/mysqlc_types.cxx
@@ -777,7 +777,7 @@ TypeInfoDef mysqlc_types[] = {
// ----------- MySQL-Type: TIMESTAMP SDBC-Type: TIMESTAMP ----------
{
- 0, 0, 0, 0, 0, 0, 0, false, 0, false, false, false, 0, 0, 0, 0, 0, 0
+ nullptr, 0, 0, nullptr, nullptr, nullptr, 0, false, 0, false, false, false, nullptr, 0, 0, 0, 0, 0
}
};