* Returns information about the block that a block reference refers to. * * If the WAL record contains a block reference with the given ID, *rnode, * *forknum, and *blknum are filled in (if not NULL), and returns true. * Otherwise returns false. */
| 1540 | * Otherwise returns false. |
| 1541 | */ |
| 1542 | bool |
| 1543 | XLogRecGetBlockTag(XLogReaderState *record, uint8 block_id, |
| 1544 | RelFileNode *rnode, ForkNumber *forknum, BlockNumber *blknum) |
| 1545 | { |
| 1546 | DecodedBkpBlock *bkpb; |
| 1547 | |
| 1548 | if (!record->blocks[block_id].in_use) |
| 1549 | return false; |
| 1550 | |
| 1551 | bkpb = &record->blocks[block_id]; |
| 1552 | if (rnode) |
| 1553 | *rnode = bkpb->rnode; |
| 1554 | if (forknum) |
| 1555 | *forknum = bkpb->forknum; |
| 1556 | if (blknum) |
| 1557 | *blknum = bkpb->blkno; |
| 1558 | return true; |
| 1559 | } |
| 1560 | |
| 1561 | /* |
| 1562 | * Returns the data associated with a block reference, or NULL if there is |
no outgoing calls
no test coverage detected