Skip to content

Commit

Permalink
fix: add a condition in display_data_content_and_confirm
Browse files Browse the repository at this point in the history
  • Loading branch information
keiff3r committed Nov 7, 2024
1 parent 7a10c09 commit e3c24ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/handler/withdraw.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ static bool display_data_content_and_confirm(dispatcher_context_t* dc,
value_with_ticker[i] == '.') {
i--;
}
if (i >= 0) {
if (i >= 0 && i < sizeof(value_with_ticker)) {
value_with_ticker[i + 1] = '\0';
}
// Get the second chunk that contains the data to display
Expand Down

0 comments on commit e3c24ae

Please sign in to comment.