[ 
https://issues.apache.org/jira/browse/HDFS-6291?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13982788#comment-13982788
 ] 

Vinayakumar B commented on HDFS-6291:
-------------------------------------

Yes! you are right. 
image.close() should be finally clause.

> FSImage may be left unclosed in BootstrapStandby#doRun()
> --------------------------------------------------------
>
>                 Key: HDFS-6291
>                 URL: https://issues.apache.org/jira/browse/HDFS-6291
>             Project: Hadoop HDFS
>          Issue Type: Bug
>            Reporter: Ted Yu
>            Priority: Minor
>
> At around line 203:
> {code}
>       if (!checkLogsAvailableForRead(image, imageTxId, curTxId)) {
>         return ERR_CODE_LOGS_UNAVAILABLE;
>       }
> {code}
> If we return following the above check, image is not closed.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to