HBASE-5424 HTable meet NPE when call getRegionInfo() -- REVERT

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1292646 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2012-02-23 05:01:29 +00:00
parent 6a80cf5bf9
commit 240d6bc52b
1 changed files with 12 additions and 14 deletions

View File

@ -449,11 +449,10 @@ public class HTable implements HTableInterface {
MetaScannerVisitor visitor = new MetaScannerVisitor() {
public boolean processRow(Result rowResult) throws IOException {
HRegionInfo info = Writables.getHRegionInfoOrNull(
HRegionInfo info = Writables.getHRegionInfo(
rowResult.getValue(HConstants.CATALOG_FAMILY,
HConstants.REGIONINFO_QUALIFIER));
if (info != null) {
if (!(Bytes.equals(info.getTableName(), getTableName()))) {
return false;
}
@ -469,7 +468,6 @@ public class HTable implements HTableInterface {
if (!(info.isOffline() || info.isSplit())) {
regionMap.put(new UnmodifyableHRegionInfo(info), server);
}
}
return true;
}