Skip to content

Commit

Permalink
[CBRD-24123] A fatal error can occur when the logpb_get_log_buffer_in…
Browse files Browse the repository at this point in the history
…dex() function is called because the function argument is incorrectly cast to the invalid type. (#3210) (#3788)

http://jira.cubrid.org/browse/CBRD-24123
  • Loading branch information
hornetmj authored Aug 31, 2022
1 parent 8a6a188 commit 1ab9713
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/transaction/log_page_buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ logpb_locate_page (THREAD_ENTRY * thread_p, LOG_PAGEID pageid, PAGE_FETCH_MODE f
}
else
{
index = logpb_get_log_buffer_index ((int) pageid);
index = logpb_get_log_buffer_index (pageid);
if (index >= 0 && index < log_Pb.num_buffers)
{
log_bufptr = &log_Pb.buffers[index];
Expand Down Expand Up @@ -1741,7 +1741,7 @@ logpb_copy_page (THREAD_ENTRY * thread_p, LOG_PAGEID pageid, LOG_CS_ACCESS_MODE
goto exit;
}

index = logpb_get_log_buffer_index ((int) pageid);
index = logpb_get_log_buffer_index (pageid);
if (index >= 0 && index < log_Pb.num_buffers)
{
log_bufptr = &log_Pb.buffers[index];
Expand Down

0 comments on commit 1ab9713

Please sign in to comment.