summaryrefslogtreecommitdiff
path: root/xmlsecurity
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2012-12-28 21:34:08 +0100
committerJulien Nabet <serval2412@yahoo.fr>2012-12-28 21:34:08 +0100
commita5ee0319aa5162db9e4611449760568d9a2cb37f (patch)
treed3e54b57527aba46665334f66cfb27f4c79a860d /xmlsecurity
parent37abf7e62941af5c697ae4cd0c3dcd58d88f156e (diff)
Fix "scope can be reduced" for 2 variables
Change-Id: I200d7c545e82fd2167f22f5522033d6e64b975f8
Diffstat (limited to 'xmlsecurity')
-rw-r--r--xmlsecurity/source/xmlsec/xmlstreamio.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/xmlsecurity/source/xmlsec/xmlstreamio.cxx b/xmlsecurity/source/xmlsec/xmlstreamio.cxx
index a06b85f5521a..1f85dc3e81d2 100644
--- a/xmlsecurity/source/xmlsec/xmlstreamio.cxx
+++ b/xmlsecurity/source/xmlsec/xmlstreamio.cxx
@@ -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() ;
}