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

Stefano Baghino edited comment on FLINK-3668 at 3/25/16 5:09 PM:
-----------------------------------------------------------------

Maybe I don't have a clear picture, but judging from the snippet you posted it 
looks like when the {{InterruptedException}} is caught an {{IOException}} is 
thrown, so the following line wouldn't be accessible at that point, right?


was (Author: stefanobaghino):
Maybe I don't have a clear picture, but judging from the snippet you posted it 
looks like that when the {{InterruptedException}} is caught an {{IOException}} 
is thrown, so the following line wouldn't be accessible at that point, right?

> Potential null deference in HadoopInputFormatBase#createInputSplits()
> ---------------------------------------------------------------------
>
>                 Key: FLINK-3668
>                 URL: https://issues.apache.org/jira/browse/FLINK-3668
>             Project: Flink
>          Issue Type: Bug
>            Reporter: Ted Yu
>            Priority: Minor
>
> Here is the code:
> {code}
>     List<org.apache.hadoop.mapreduce.InputSplit> splits;
>     try {
>       splits = this.mapreduceInputFormat.getSplits(jobContext);
>     } catch (InterruptedException e) {
>       throw new IOException("Could not get Splits.", e);
>     }
>     HadoopInputSplit[] hadoopInputSplits = new 
> HadoopInputSplit[splits.size()];
> {code}
> If InterruptedException is caught, splits would be null.
> Yet, the next line accesses splits.size() without null check.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to