https://bugs.kde.org/show_bug.cgi?id=374568
--- Comment #8 from Eugene Shalygin <eugene.shalygin+bugzilla....@gmail.com> --- (In reply to RJVB from comment #7) > You must have hit a border condition. I disagree. AFAIK, the code shall lead to UB, because we call a virtual function from an object, whose constuctor was not called (HackedMenu). This is what I meant earlier when said that I can't understand how this could work. In support of this version, if I call the method explicitly specifying the class (QMenuBar::event(ev)) it does not crash and under debugger I see that the function is actually called. In the original code, the execution jumps to random location, which I can change by moving HackedMenu declaration around (e.g. moving it out of the function to an anonymous namespace or making it public class). > Please try to debug and obtain a proper backtrace. As such I think the backtrace is correct. It does differ from our expectations, but this is because of UB. I just can't understand why does it work in Qt 4 version... -- You are receiving this mail because: You are watching all bug changes.