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

Steve Loughran commented on HADOOP-10542:
-----------------------------------------

I think we need to look at why the error "NoSuchKey" is being mapped to 
{{null}}, rather than raise an exception -and for the selective reporting in 
{{handleServiceException()}}. Do that -and provide a useful error, and the 
deref here goes away. 

 HADOOP-10533 seems related.

> Potential null pointer dereference in Jets3tFileSystemStore#retrieveBlock()
> ---------------------------------------------------------------------------
>
>                 Key: HADOOP-10542
>                 URL: https://issues.apache.org/jira/browse/HADOOP-10542
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs/s3
>            Reporter: Ted Yu
>            Priority: Minor
>
> {code}
>       in = get(blockToKey(block), byteRangeStart);
>       out = new BufferedOutputStream(new FileOutputStream(fileBlock));
>       byte[] buf = new byte[bufferSize];
>       int numRead;
>       while ((numRead = in.read(buf)) >= 0) {
> {code}
> get() may return null.
> The while loop dereferences in without null check.



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

Reply via email to