[ 
https://issues.apache.org/jira/browse/HBASE-22461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

wuguihu updated HBASE-22461:
----------------------------
    Attachment: HBASE-22461.patch
        Status: Patch Available  (was: Open)

> A "NullPointerException" could be thrown; "Result" is nullable
> --------------------------------------------------------------
>
>                 Key: HBASE-22461
>                 URL: https://issues.apache.org/jira/browse/HBASE-22461
>             Project: HBase
>          Issue Type: Bug
>          Components: Client
>    Affects Versions: 2.1.4
>            Reporter: wuguihu
>            Priority: Major
>             Fix For: 3.0.0
>
>         Attachments: HBASE-22461.patch
>
>
> In hbase-client model the class  
> "org.apache.hadoop.hbase.MetaTableAccessor"'s method getRegionInfo(final 
> Result r, byte [] qualifier),A "NullPointerException" could be thrown; "r" is 
> nullable here.
>  
> {code:java}
> @Nullable
> private static RegionInfo getRegionInfo(final Result r, byte [] qualifier) {
>   Cell cell = r.getColumnLatestCell(getCatalogFamily(), qualifier);
>   if (cell == null) return null;
>   return RegionInfo.parseFromOrNull(cell.getValueArray(),
>     cell.getValueOffset(), cell.getValueLength());
> }
> {code}
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to