Hi Sameera,

This fix needs to be applied to the patch 0009 of the kernel too.

Thank you,
SameeraK.

On Wed, Sep 10, 2014 at 6:21 PM, Aruna Karunarathna <ar...@wso2.com> wrote:

> Thanks SameeraK.
>
> Regards,
> Aruna
>
> On Wed, Sep 10, 2014 at 5:59 PM, Sameera Kannangara <samee...@wso2.com>
> wrote:
>
>> Hi Aruna,
>>
>> Please find pull request at [1].
>>
>> Thank you,
>> SameeraK.
>>
>> [1] https://github.com/wso2-dev/carbon4-kernel/pull/94
>>
>> On Wed, Sep 10, 2014 at 3:43 PM, Aruna Karunarathna <ar...@wso2.com>
>> wrote:
>>
>>> Hi SameeraK,
>>>
>>> Can you send a pull request for the above mentioned ticket?.
>>>
>>> Regards,
>>> Aruna
>>>
>>> --
>>>
>>> *Aruna Sujith Karunarathna* | Software Engineer
>>> WSO2, Inc | lean. enterprise. middleware.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 71 9040362 | Work: +94 112145345
>>> Email: ar...@wso2.com | Web: www.wso2.com
>>>
>>>
>>
>>
>>
>> --
>> *Sameera Kannangara*
>> Software Engineer
>> Platform TG; WSO2 Inc. http://wso2.com
>> Contact:
>> phone: +94719541577
>> Lean . Enterprise . Middleware
>>
>
>
>
> --
>
> *Aruna Sujith Karunarathna* | Software Engineer
> WSO2, Inc | lean. enterprise. middleware.
> #20, Palm Grove, Colombo 03, Sri Lanka
> Mobile: +94 71 9040362 | Work: +94 112145345
> Email: ar...@wso2.com | Web: www.wso2.com
>
>



-- 
*Sameera Kannangara*
Software Engineer
Platform TG; WSO2 Inc. http://wso2.com
Contact:
phone: +94719541577
Lean . Enterprise . Middleware
Index: src/main/java/org/wso2/carbon/registry/core/jdbc/Repository.java
===================================================================
--- src/main/java/org/wso2/carbon/registry/core/jdbc/Repository.java	(revision 206446)
+++ src/main/java/org/wso2/carbon/registry/core/jdbc/Repository.java	(working copy)
@@ -1256,7 +1256,12 @@
                 }
             }
         }
-        DumpReader dumpReader = new DumpReader(reader);
+        DumpReader dumpReader = new DumpReader(reader){
+            @Override
+            public void close() throws IOException {
+                // close the inner stream on finally block
+            }
+        };
         XMLStreamReader xmlReader;
         try {
             xmlReader = XMLInputFactory.newInstance().createXMLStreamReader(dumpReader);
@@ -1271,6 +1276,14 @@
             String msg = "Failed to serialize the dumped element at " + path + ".";
             log.error(msg, e);
             throw new RegistryException(msg, e);
+        } finally{
+            if(reader!=null){
+                try {
+                    reader.close();
+                } catch (IOException e) {
+                    //ignored
+                }
+            }
         }
     }
 
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to