Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Graphics
Krita
Commits
44c4f74a
Commit
44c4f74a
authored
Aug 22, 2022
by
Sharaf Zaman
Browse files
Fix nullptr crash: srcImage may not exist when deep-copying layers
BUG:458115
parent
62c90ec3
Pipeline
#221127
passed with stage
in 53 minutes and 46 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
libs/ui/kis_mimedata.cpp
View file @
44c4f74a
...
...
@@ -213,8 +213,9 @@ void KisMimeData::initializeExternalNode(KisNodeSP *node,
// attach the layer to a new shape controller
KisShapeLayer
*
shapeLayer2
=
new
KisShapeLayer
(
*
shapeLayer
,
shapeController
);
if
(
!
qFuzzyCompare
(
dstImage
->
xRes
(),
srcImage
->
xRes
())
||
!
qFuzzyCompare
(
dstImage
->
yRes
(),
srcImage
->
yRes
()))
{
if
(
srcImage
&&
(
!
qFuzzyCompare
(
dstImage
->
xRes
(),
srcImage
->
xRes
())
||
!
qFuzzyCompare
(
dstImage
->
yRes
(),
srcImage
->
yRes
())))
{
const
QTransform
t
=
QTransform
::
fromScale
(
srcImage
->
xRes
()
/
dstImage
->
xRes
(),
srcImage
->
yRes
()
/
dstImage
->
yRes
());
...
...
Sharaf Zaman
@szaman
mentioned in commit
39a56110
·
Aug 25, 2022
mentioned in commit
39a56110
mentioned in commit 39a56110b50dc1246e76e891ac575ba8e9c613b5
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment