Skip to content

Fixes a gbak restore crash for backups created with -e#8994

Merged
hvlad merged 1 commit intoFirebirdSQL:masterfrom
MochalovAlexey:burp_filereader_buffer_length_fix
Apr 20, 2026
Merged

Fixes a gbak restore crash for backups created with -e#8994
hvlad merged 1 commit intoFirebirdSQL:masterfrom
MochalovAlexey:burp_filereader_buffer_length_fix

Conversation

@MochalovAlexey
Copy link
Copy Markdown
Contributor

@MochalovAlexey MochalovAlexey commented Apr 20, 2026

The bug was reproduced on a real production database backup (5.0 ver.). The restore reader now reserves one extra byte in IOBuffer for the next rec_* marker after a data record. A record could exactly fill the buffer and trip fb_assert(space > 0) before writing rec_data or rec_relation_end.

Copy link
Copy Markdown
Member

@hvlad hvlad left a comment

Choose a reason for hiding this comment

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

Good catch, thanks

@hvlad hvlad self-assigned this Apr 20, 2026
@hvlad hvlad merged commit c4bbd0a into FirebirdSQL:master Apr 20, 2026
22 of 23 checks passed
hvlad added a commit that referenced this pull request Apr 20, 2026
…ength_fix

Fixes a gbak restore crash for backups created with `-e`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants