-
Notifications
You must be signed in to change notification settings - Fork 193
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
Occasional crashes when modifying effects in AC mode #1021
Comments
Yeah. I think I will have this fixed in .41. I just can't be sure. |
@keithsw1111 Any insights as to where/how it happens? It seems like a use-after-free case, possibly where member functions of an effect are called on an effect that has been deleted. I have a fairly strong C++ background and have been digging into this myself as well. |
Log from GCC7 + libasan memory safety analyser: 0x613000075b60 is located 32 bytes inside of 336-byte region [0x613000075b40,0x613000075c90) previously allocated by thread T0 here: |
Confirmed as a UAF bug; it looks like the order of processing of the mouse up and SelectedEffectChanged does not always occur in order: RaiseSelectedEffectChanged (call to RaiseSelectedEffectChanged) |
Regarding testing with Dan's recent changes (discussed in the PR more extensively), as of release 2017.42, this crash still occurs: xLights version 2017.42 64bit xLights(_Z11handleCrashPv+0xc35) [0x55a824154675] Crashed thread id: 0x7AABB9C0 or 2058074560 |
To take this forward I need a reliable way to reproduce it. |
Replacing a several effects with a different effect in rapid succession with AC mode active will trigger this within at most 20 replace actions. The crash happens much sooner if the mouse button is held for a very short time while doing such, since it seems to greatly increase the probability of the mouse up event being handled before the SelectedEffectChanged is handled (which triggers the UAF and crash). I will setup a VM with the exact same environment (fully updated Arch Linux) that I can reliably reproduce the issue in and make the image available if that helps. |
I also noticed you mentioned that a variant of #1022 was incorporated. Will retest to see if i can still reproduce on the latest code. |
Please reopen if it is not resolved. |
Hello,
With xLights 2017.39 and 2017.40, I am experiencing occasional crashes when modifying effects in AC mode. All effects in question are single color on/off/ramp effects applied to line models.
I can reproduce this consistently via the following steps:
Enter AC mode, replace (individually) several ramp effects with intensity effects in rapid succession and this crash will occur.
I am running xLights on Arch Linux, fully updated as of 12/8/17.
Looking at the debug reports. is appears that the crash is consistently occurring within xLightsFrame::SetEffectControls.
Debug Reports:
xLights_dbgrpt-31273-20171208T004825.zip
xLights_dbgrpt-1152-20171208T235047.zip
xLights_dbgrpt-24885-20171209T001609.zip
The text was updated successfully, but these errors were encountered: