Bug 459800 - Krita Crashes When Attempting to Create a New Image From Empty Clipboard
Summary: Krita Crashes When Attempting to Create a New Image From Empty Clipboard
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: General (show other bugs)
Version: 5.1.1
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: amyspark
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-09-28 19:43 UTC by John
Modified: 2022-11-01 18:18 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John 2022-09-28 19:43:12 UTC
Krita crashes when attempting to create a new image from clipboard and there is no available image data in the clipboard. Situation could be accidental (ie. User unaware the Create from Clipboard option is active because of interface similarity. If Create from Clipboard is used in the previous session, the new image window starts with Create from Clipboard active) or somehow copying an image to the clipboard was not successful.


STEPS TO REPRODUCE
1. No image in the clipboard (fresh OS session, etc)
2. Set desired image options (my case: 12.7inx9in, 300dpi, 1 layer with gray canvas color)
3. Click 'Create' button

OBSERVED RESULT
Krita crashes without any error messages.

EXPECTED RESULT
'Create' button grayed out or some error message warning me of impossibility of creating an image without Clipboard data.

SOFTWARE/OS VERSIONS
Linux: Linux Mint 
Qt Version: 5.12.12

ADDITIONAL INFORMATION

KRITA DID NOT CLOSE CORRECTLY
================================================================================
SESSION: 28 Sep 2022 14:05:34 -0500. Executing /tmp/.mount_krita-TD2tRH/usr/bin/krita

Krita Version: 5.1.1, Qt version compiled: 5.12.12, loaded: 5.12.12. Process ID: 259537
-- -- -- -- -- -- -- --

---------------------
qt5ct: using qt5ct plugin
Replacing libstdc++.so.6 with the fallback version: libstdc++.so.6.0.28 -> libstdc++.so.6.0.29
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
krita.general: ERROR: unable to decode abr format version  9 (subver  0 )
QObject::startTimer: Timers cannot have negative intervals
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
/tmp/.mount_krita-LUOYUK/usr/lib/krita-python-libs/krita added to PYTHONPATH
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
WARNING: vector instructions disabled by the 'amdDisableVectorWorkaround' option!
ASSERT (krita): "!qimage.isNull()" in file /home/appimage/workspace/Krita_Release_Appimage_Build/krita/libs/ui/kis_clipboard.cc, line 460
Comment 1 Bug Janitor Service 2022-10-25 22:58:42 UTC
A possibly relevant merge request was started @ https://invent.kde.org/graphics/krita/-/merge_requests/1630
Comment 2 amyspark 2022-11-01 18:17:03 UTC
Git commit e859c42198e2ae60d1125ef533030abe2f2e9b6e by L. E. Segovia.
Committed on 01/11/2022 at 18:14.
Pushed by lsegovia into branch 'krita/5.1'.

KisImageFromClipboardWidget: do not attempt to create an image with an empty clipboard

M  +3    -4    libs/ui/widgets/kis_image_from_clipboard_widget.cpp

https://invent.kde.org/graphics/krita/commit/e859c42198e2ae60d1125ef533030abe2f2e9b6e
Comment 3 amyspark 2022-11-01 18:17:11 UTC
Git commit 688d762badc94e0f922a6f38aa61f0a5744f76fa by L. E. Segovia.
Committed on 01/11/2022 at 18:14.
Pushed by lsegovia into branch 'krita/5.1'.

KisImageFromClipboardWidget: fix wrong order of showEvent() handling

This fixes the Create button being improperly enabled after the
Clipboard widget determined there is no image available.

M  +2    -1    libs/ui/widgets/kis_image_from_clipboard_widget.cpp

https://invent.kde.org/graphics/krita/commit/688d762badc94e0f922a6f38aa61f0a5744f76fa
Comment 4 amyspark 2022-11-01 18:17:19 UTC
Git commit 7380f22b00b4bd5be33c9558d0764b95db0e04a3 by L. E. Segovia.
Committed on 01/11/2022 at 18:14.
Pushed by lsegovia into branch 'krita/5.1'.

Create New Document: fix Create button enabled when the clipboard has no images

M  +14   -12   libs/ui/widgets/kis_image_from_clipboard_widget.cpp
M  +3    -4    libs/ui/widgets/kis_image_from_clipboard_widget.h

https://invent.kde.org/graphics/krita/commit/7380f22b00b4bd5be33c9558d0764b95db0e04a3
Comment 5 amyspark 2022-11-01 18:17:55 UTC
Git commit ec7ba6abafb87180fddd02a35fecf3ba1713e0ba by L. E. Segovia.
Committed on 01/11/2022 at 18:16.
Pushed by lsegovia into branch 'master'.

Create New Document: fix Create button enabled when the clipboard has no images
(cherry picked from commit 7380f22b00b4bd5be33c9558d0764b95db0e04a3)

M  +14   -12   libs/ui/widgets/kis_image_from_clipboard_widget.cpp
M  +3    -4    libs/ui/widgets/kis_image_from_clipboard_widget.h

https://invent.kde.org/graphics/krita/commit/ec7ba6abafb87180fddd02a35fecf3ba1713e0ba
Comment 6 amyspark 2022-11-01 18:18:03 UTC
Git commit 090184c9a8df0120fc4aab08cab27cf7db646058 by L. E. Segovia.
Committed on 01/11/2022 at 18:16.
Pushed by lsegovia into branch 'master'.

KisImageFromClipboardWidget: fix wrong order of showEvent() handling

This fixes the Create button being improperly enabled after the
Clipboard widget determined there is no image available.
(cherry picked from commit 688d762badc94e0f922a6f38aa61f0a5744f76fa)

M  +2    -1    libs/ui/widgets/kis_image_from_clipboard_widget.cpp

https://invent.kde.org/graphics/krita/commit/090184c9a8df0120fc4aab08cab27cf7db646058
Comment 7 amyspark 2022-11-01 18:18:11 UTC
Git commit e0f66e497ad7582a54fdb8b28b2ae810d15f514e by L. E. Segovia.
Committed on 01/11/2022 at 18:16.
Pushed by lsegovia into branch 'master'.

KisImageFromClipboardWidget: do not attempt to create an image with an empty clipboard
(cherry picked from commit e859c42198e2ae60d1125ef533030abe2f2e9b6e)

M  +3    -4    libs/ui/widgets/kis_image_from_clipboard_widget.cpp

https://invent.kde.org/graphics/krita/commit/e0f66e497ad7582a54fdb8b28b2ae810d15f514e