!5693 【openGauss】【bugfix】【query_page_distribution_info系统函数】memcpy_s传参不合理,造成栈链被破坏

Merge pull request !5693 from 董宁/bugfix28_up
This commit is contained in:
opengauss_bot
2024-06-28 09:11:09 +00:00
committed by Gitee

View File

@ -2170,7 +2170,7 @@ int CBOndemandRedoPageForStandby(void *block_key, int32 *redo_status)
void CBGetBufInfo(char* resid, stat_buf_info_t *buf_info)
{
BufferTag tag;
errno_t err = memcpy_s(&tag, DMS_RESID_SIZE, resid, DMS_RESID_SIZE);
errno_t err = memcpy_s(&tag, sizeof(BufferTag), resid, sizeof(BufferTag));
securec_check(err, "\0", "\0");
buftag_get_buf_info(tag, buf_info);
}