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
Segfault in gbak when restoring broken backup file over the wire #7204
Comments
…the wire (cherry picked from commit 7d9f9f2)
::: test issues ::: |
Pavel, I definitely do not remember that letter in Feb. What info do you need? |
In that letter I meant the following: what must be written in a fbk file to make it in such 'broken state' that attempt to restore from it caused crash ?
(or some other error, but FB not crashed |
You should try to make length of damaged record much bigger (like 40 Kb instead 1 Kb) than normal one. But that also does not guarantee crash - it's related with double de-allocation of same memory region, and may cause AV not at once or not cause at all. |
I suggest not to have special test for it - even if you reproduce a crash with some particular version (fb4 for example) that does not mean that same data kills fb3 or fb5. |
|
Reported by Vlad privately.
gbak predicts the size of data buffer in XDR operations required for table record. But in case of broken data in backup file data is reallocated which together with a fact that original buffer is freed in Array's dtor once again causes double deallocation and segfault.
The text was updated successfully, but these errors were encountered: