Fix "scope can be reduced" for 2 variables

Change-Id: I200d7c545e82fd2167f22f5522033d6e64b975f8
This commit is contained in:
Julien Nabet
2012-12-28 21:34:08 +01:00
parent 37abf7e629
commit a5ee0319aa

View File

@@ -80,7 +80,6 @@ extern "C"
void* xmlStreamOpen( const char* uri )
{
::com::sun::star::uno::Reference< com::sun::star::io::XInputStream > xInputStream ;
::com::sun::star::io::XInputStream* pInputStream ;
if( ( enableXmlStreamIO & XMLSTREAMIO_INITIALIZED ) &&
( enableXmlStreamIO & XMLSTREAMIO_REGISTERED ) ) {
@@ -101,6 +100,7 @@ void* xmlStreamOpen( const char* uri )
}
if( xInputStream.is() ) {
::com::sun::star::io::XInputStream* pInputStream ;
pInputStream = xInputStream.get() ;
pInputStream->acquire() ;
return ( void* )pInputStream ;
@@ -138,11 +138,10 @@ int xmlStreamRead( void* context, char* buffer, int len )
extern "C"
int xmlStreamClose( void * context )
{
::com::sun::star::io::XInputStream* pInputStream ;
if( ( enableXmlStreamIO & XMLSTREAMIO_INITIALIZED ) &&
( enableXmlStreamIO & XMLSTREAMIO_REGISTERED ) ) {
if( context != NULL ) {
::com::sun::star::io::XInputStream* pInputStream ;
pInputStream = ( ::com::sun::star::io::XInputStream* )context ;
pInputStream->release() ;
}