Bug 143815 - EDITING: images duplicated after undo
Summary: EDITING: images duplicated after undo
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.2.0.0.alpha0+
Hardware: All All
: high major
Assignee: Not Assigned
URL:
Whiteboard: target:7.3.0 target:7.2.3
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Writer-Images Undo-Redo
  Show dependency treegraph
 
Reported: 2021-08-10 20:12 UTC by Xisco Faulí
Modified: 2022-04-20 18:40 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
sample file (10.72 KB, application/vnd.oasis.opendocument.text)
2021-08-10 20:12 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2021-08-10 20:12:16 UTC
Created attachment 174194 [details]
sample file

I found this issue while creating a unittest for bug 135247

Steps to reproduce:
1. Open attached document ( Same as sw/qa/extras/uiwriter/data/tdf132911.odt )
2. Select all
3. Cut
4. Paste - 4 images
5. Paste - 8 images
6. Undo - 4 images
7. Undo - 0 images
8. Undo

At this point, the number of images should be 4, however, there are 8 images in the document

Reproduced in

Version: 7.3.0.0.alpha0+ / LibreOffice Community
Build ID: 6e53e03f752c2f85283c4d47efaaf0683299783c
CPU threads: 4; OS: Linux 5.7; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded
Comment 1 Xisco Faulí 2021-08-10 20:13:30 UTC
Note: The navigator says there are 4 images but if you scroll down and count the images, there are 8
Comment 2 Xisco Faulí 2021-08-10 20:19:00 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=188ec34cf157ffee8c63f03f420ca9daafb5ff29

author	Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>	2020-12-12 23:44:26 +0100
committer	Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>	2020-12-30 10:47:05 +0100
commit 188ec34cf157ffee8c63f03f420ca9daafb5ff29 (patch)
tree c1a24efdaf13076fd9e3d4597976e5290c5630bb
parent b808610533fce13228c4f4ad8924586b560a5928 (diff)
atrflyin.cxx Modify no more

Bisected with: bibisect-linux64-7.2

Adding Cc: to Bjoern Michaelsen
Comment 3 Xisco Faulí 2021-08-10 20:19:58 UTC
Increasing importance since bug 140798 and bug 141659 are also affected by the same commit
Comment 4 Björn Michaelsen 2021-10-25 19:39:04 UTC
https://gerrit.libreoffice.org/c/core/+/124162
Comment 5 Commit Notification 2021-10-29 11:24:41 UTC
Bjoern Michaelsen committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/3cfd63cb55ab1a7e6df53eaeb2a7623be05983d0

tdf#140798, tdf#143815, tdf#141659: fix fly content hint handling

It will be available in 7.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Commit Notification 2021-11-03 10:57:04 UTC
Bjoern Michaelsen committed a patch related to this issue.
It has been pushed to "libreoffice-7-2":

https://git.libreoffice.org/core/commit/84c8adb703906b0fe2c7f9a5e7174e00139a08f3

tdf#140798, tdf#143815, tdf#141659: fix fly content hint handling

It will be available in 7.2.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Justin L 2021-11-10 08:48:47 UTC
I presume this should be closed as fixed.
I confirm that only 4 images are showing and everything is back to original state in master after a cut, paste, paste, undo, undo, undo.
Comment 8 Jean-Baptiste Faure 2022-04-20 18:40:26 UTC
The commit for this bug generates a new regression : bug 148691

Best regards. JBF