fix caching in OResultColumn

this obviously never worked, because the template method was never
updating the cache field, just a copy of the cache field

Change-Id: Ibeed9a0f0764a4d398548c05aed466cd6cdfc266
This commit is contained in:
Noel Grandin 2017-09-18 16:06:47 +02:00
parent ba91bc1902
commit c087e24c68

View File

@ -167,7 +167,7 @@ void OResultColumn::disposing()
namespace
{
template< typename T >
void obtain( Any& _out_rValue, ::boost::optional< T > _rCache, const sal_Int32 _nPos, const Reference < XResultSetMetaData >& _rxResultMeta, T (SAL_CALL XResultSetMetaData::*Getter)( sal_Int32 ) )
void obtain( Any& _out_rValue, ::boost::optional< T > & _rCache, const sal_Int32 _nPos, const Reference < XResultSetMetaData >& _rxResultMeta, T (SAL_CALL XResultSetMetaData::*Getter)( sal_Int32 ) )
{
if ( !_rCache )
_rCache.reset( (_rxResultMeta.get()->*Getter)( _nPos ) );