Removing an xtext annotation twice doesn't throw an exception

Hamish MB hamishmb at live.co.uk
Sat Mar 23 10:35:32 UTC 2019


While I was improving some of the python unit tests, I found something strange in /sw/qa/python/xtext.py: you can remove the same annotation twice without any kind of warning or error.

What follows is the description of the bug at https://bugs.documentfoundation.org/show_bug.cgi?id=123404

When creating and removing annotations as shown in /sw/qa/python/xtext.py, annotations can be removed twice without causing exceptions or any kind of warning. This seems to be a silent failure, but I don't know if there are any side effects of doing this.

Steps to Reproduce:
1. Run the xtext unit test:
2. cd sw
3. make PythonTest_sw_python PYTHON_TEST_NAME="xtext"
4. The test completes successfully, even though it removes annotations twice.

Actual Results:
The test completes - unexpected success.

Expected Results:
The test as it is at the moment should fail in some way - throw an exception. I expected it to segfault, but it doesn't.


Reproducible: Always


User Profile Reset: No

I'm wondering whether this is intended behaviour, or whether this is something that should be fixed. The note in the unit test seems to imply it was unexpected. I''m happy to help fix this if it is decided that a fix is needed, but I may need some help as I don't have very much experience with Libreoffice's codebase yet.

Hamish McIntyre-Bhatty

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20190323/43d7a91c/attachment.html>


More information about the LibreOffice mailing list