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
[CritFix] - Fix reported length of logging structure #4732
Conversation
The logging code contains one place where the apparent size of the logging structure is defined and then it's actually utilized in another place. Re-writes and refactoring this code ended up with these values to not co-relate what was previously there resulting in a stack overwrite in last version or currently in log truncation. Move assignment of logging structure to the place where it's actually used, reducing future logic de-sync dangers. Also move the g_assert() to the end as it should be a development aid only.
I can open a bug report for this, if necessary. But in currently released version, there is a stack variable overflow because of this disjoint logic that results in crash on start.
In the
|
Nice, I'm really curious why no CI test has detected this issue :) However, it seems that we have one now thanks to @fatalbanana |
Supposing 3.7.5 works you might use that without patches. 3.8.0 will be patched as here. |
so basically this patch will get reverted and replaced with your 2 patches? |
no, more like the inverse (my commits are in the old branch, this is the forward-looking branch). maybe yes depending on the context? more likely no... |
The logging code contains one place where the apparent size of the logging structure is defined and then it's actually utilized in another place. Re-writes and refactoring this code ended up with these values to not co-relate what was previously there resulting in a stack overwrite in last version or currently in log truncation.
Move assignment of logging structure to the place where it's actually used, reducing future logic de-sync dangers. Also move the g_assert() to the end as it should be a development aid only.