提交 3abb11ec 编写于 作者: O obdev 提交者: wangzelin.wzl

fix coredump

上级 45e229b8
...@@ -1272,12 +1272,17 @@ int ObArchiveStore::get_piece_paths_in_range(const int64_t start_scn, const int6 ...@@ -1272,12 +1272,17 @@ int ObArchiveStore::get_piece_paths_in_range(const int64_t start_scn, const int6
} }
} }
if (OB_SUCC(ret)) { if (OB_FAIL(ret)) {
} else if (-1 == last_piece_idx) {
ret = OB_ENTRY_NOT_EXIST;
LOG_WARN("no enough log for restore", K(ret), K(last_piece_idx), K(end_scn));
LOG_USER_ERROR(OB_ENTRY_NOT_EXIST, "No enough log for restore");
} else {
const ObTenantArchivePieceAttr &last_piece = piece_whole_info.his_frozen_pieces_.at(last_piece_idx); const ObTenantArchivePieceAttr &last_piece = piece_whole_info.his_frozen_pieces_.at(last_piece_idx);
if (last_piece.checkpoint_scn_ < end_scn) { if (last_piece.checkpoint_scn_ < end_scn) {
ret = OB_ENTRY_EXIST; ret = OB_ENTRY_NOT_EXIST;
LOG_WARN("no enough log for restore", K(ret), K(last_piece), K(end_scn)); LOG_WARN("no enough log for restore", K(ret), K(last_piece), K(end_scn));
LOG_USER_ERROR(OB_ENTRY_EXIST, "No enough log for restore"); LOG_USER_ERROR(OB_ENTRY_NOT_EXIST, "No enough log for restore");
} }
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册