| Summary: | Crash while using move tool with a large layer | ||
|---|---|---|---|
| Product: | [Applications] krita | Reporter: | acc4commissions |
| Component: | Layer Stack | Assignee: | Dmitry Kazakov <dimula73> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | ghevan, halla, scottpetrovic |
| Priority: | NOR | Keywords: | regression |
| Version First Reported In: | nightly build (please specify the git hash!) | ||
| Target Milestone: | --- | ||
| Platform: | Microsoft Windows | ||
| OS: | Microsoft Windows | ||
| Latest Commit: | https://invent.kde.org/kde/krita/commit/d0f011a061c522dd0d0ff251e4aa4cd916ce22d3 | Version Fixed/Implemented In: | |
| Sentry Crash Report: | |||
|
Description
acc4commissions
2019-05-05 05:37:06 UTC
I cannot reproduce this crash on macOS in master, super slow but no crash. Tested Move tool. zoomed out zoomed in bashing the arrow keys Mouse drag. Does this crash happen every time for you, or just on occasion? I am on Windows 10 and not getting any crashes with the move tool moving things around if it is randomly, it could be related to this... kis_tool_move.cc -------- bool KisToolMove::startStrokeImpl(MoveToolMode mode, const QPoint *pos) There is an image->tryBarrierLock for threaded stuff in there, but the check might need to happen earlier in the code before image is actually used. Specifically before the KisResourceSnapShotSP tries to use the image. I've checked with valgrind and it doesn't look like there is anything weird going on. Git commit e2105bee1325b4845a2a6e5306f43f5ef5d1f6c7 by Boudewijn Rempt. Committed on 08/05/2019 at 13:08. Pushed by rempt into branch 'master'. Add checks for pointers before using them This probably doesn't solve the bug, but I've noticed that sometimes when working with larger images, a tool cannot access the current node, so that might be one reason for this crash to happen. M +2 -0 plugins/tools/basictools/kis_tool_move.cc https://invent.kde.org/kde/krita/commit/e2105bee1325b4845a2a6e5306f43f5ef5d1f6c7 *** Bug 407632 has been marked as a duplicate of this bug. *** Ok it was not random. How to reproduce : 1. Open any document and select Move Tool(Or use it). 2. Close the document. (Do not close the krita application) 3. Open an another document. And select Move Tool. 4. Press any arrow key. 5. Crash. This might be windows-specific; it does not crash on my linux system. I don't know what happened but it doesn't seem to crash anymore in the lastest nightly. (git 28fed10) (In reply to acc4commissions from comment #9) > I don't know what happened but it doesn't seem to crash anymore in the > lastest nightly. (git 28fed10) Still crash in beta version though. I'm apologize. I mistook an old nightly 4.1.7 for the new 4.2 one. I'm really sorry for (In reply to acc4commissions from comment #9) > I don't know what happened but it doesn't seem to crash anymore in the > lastest nightly. (git 28fed10) I apologize. I mistook an old 4.1.7 nightly for the new 4.2 one. I'm really sorry for being idiotic on this. I'll think twice before repoting anything. :/ Yes, I can reproduce the crash, thank you! :) Git commit 45bdec0ecd0b48fcc423d91e42ca49e8acd2a177 by Dmitry Kazakov. Committed on 23/05/2019 at 15:56. Pushed by dkazakov into branch 'master'. Make sure active tool is deactivated before closing the document When a document is closed, its canvas gets destroyed. The problem is that the tools get destroyed in active state. That might be not very obvious from API point of view. NOTE1: do *not* backport it to 4.2, the patch is too dangerous NOTE2: this patch is *not* a fix for 407228, it is just related M +1 -0 libs/flake/KoToolManager.cpp https://invent.kde.org/kde/krita/commit/45bdec0ecd0b48fcc423d91e42ca49e8acd2a177 Git commit 4622b00348ce7973f53245930506aef5099c9850 by Dmitry Kazakov. Committed on 23/05/2019 at 15:56. Pushed by dkazakov into branch 'master'. Fix crash in move tool after closing the document We shouldn't use lambda functions in signal connection if we need to control lifetime of the connection. In this very case, the connection was still active after destruciton of KisToolMove and lambda still stored a pointer to destroyed 'this'. BACKPORT:krita/4.2 M +58 -46 plugins/tools/basictools/kis_tool_move.cc M +11 -0 plugins/tools/basictools/kis_tool_move.h https://invent.kde.org/kde/krita/commit/4622b00348ce7973f53245930506aef5099c9850 Git commit d0f011a061c522dd0d0ff251e4aa4cd916ce22d3 by Boudewijn Rempt, on behalf of Dmitry Kazakov. Committed on 24/05/2019 at 10:17. Pushed by rempt into branch 'krita/4.2'. Fix crash in move tool after closing the document We shouldn't use lambda functions in signal connection if we need to control lifetime of the connection. In this very case, the connection was still active after destruciton of KisToolMove and lambda still stored a pointer to destroyed 'this'. BACKPORT:krita/4.2 (cherry picked from commit 4622b00348ce7973f53245930506aef5099c9850) M +58 -46 plugins/tools/basictools/kis_tool_move.cc M +11 -0 plugins/tools/basictools/kis_tool_move.h https://invent.kde.org/kde/krita/commit/d0f011a061c522dd0d0ff251e4aa4cd916ce22d3 |