Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MDEV-35818: Fix replace_binlog_file info message #3746

Open
wants to merge 1 commit into
base: 11.7
Choose a base branch
from

Conversation

ParadoxV5
Copy link
Contributor

Description

ATTRIBUITE_FORMAT from #3360 uncovers issues on my_snprintf uses.
This commit fixes the one in Binlog_commit_by_rotate:: replace_binlog_file() about “required size too big”.

All I found is that it’s not present in 11.4 (after I prepared previous batches for all maintained branches), for GitHub blame can’t process a file with over 10K lines.

Release Notes

But 11.7 wasn’t Generally Available yet?

How can this PR be tested?

I suppose we can trigger this issue by running the simulate_required_size_too_big test (wherever it is) in 32-bit Linux.

PR quality check

  • This is a new feature or a refactoring, and the PR is based against the main branch.
  • This is a bug fix, and the PR is based against the earliest maintained branch in which the bug can be reproduced.
  • I checked the CODING_STANDARDS.md file and my PR conforms to this where appropriate.
  • For any trivial modifications to the PR, I am ok with the reviewer making the changes themselves.

`ATTRIBUITE_FORMAT` from #3360 uncovers issues on `my_snprintf` uses.
This commit fixes the one in `Binlog_commit_by_rotate::`
`replace_binlog_file()` about “required size too big”.

All I found is that it’s not present in 11.4
(after I prepared previous batches for all maintained branches),
for GitHub blame can’t process a file with over 10K lines.
@ParadoxV5 ParadoxV5 changed the base branch from main to 11.7 January 10, 2025 21:37
required_size, m_cache_data->file_reserved_bytes());
"Required %zu bytes but only %lu bytes reserved.",
required_size,
(unsigned long) m_cache_data->file_reserved_bytes());
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

binlog_cache_data::file_reserved_bytes() is an uint32, which doesn’t necessarily match PRIu32’s uint32_t, so I’m up-casting for now.
MDEV-35460

ParadoxV5 added a commit to ParadoxV5/MariaDB-server that referenced this pull request Jan 10, 2025
* MariaDB#3746
* MariaDB#3747
* MariaDB#3748
* MariaDB#3749

This commit should not be merged, but skipping it before the
above PRs merge to the `main` branch will brick CIs on `main`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

2 participants