Bug 119607 - Writer: Macro: Libre crash after function getPropertyState("TextParagraph") for view cursor
Summary: Writer: Macro: Libre crash after function getPropertyState("TextParagraph") f...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.0.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.2.0 target:6.1.2
Keywords: bibisected, bisected, haveBacktrace, regression
Depends on:
Blocks:
 
Reported: 2018-08-30 13:48 UTC by Kamil Landa
Modified: 2018-09-03 17:55 UTC (History)
3 users (show)

See Also:
Crash report or crash signature: ["cppu::_destructAny(_uno_Any *,void (*)(void *))"]


Attachments
gdb backtrace (34.99 KB, text/plain)
2018-08-30 14:32 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kamil Landa 2018-08-30 13:48:09 UTC
Run from Writer this simple macro and LibreOffice will crash. 


Sub crash 'Libre crash
	dim oVCur, a
	oVCur=thisComponent.currentcontroller.getViewCursor() 'view cursor
	a=oVCur.getPropertyState("TextParagraph") 'Libre crash!; for other properties it is all right
End Sub



Verze: 6.1.0.3 (x64)
ID sestavení: efb621ed25068d70781dc026f7e9c5187a4decd1
Vlákna CPU: 2; OS: Windows 6.1; Vykreslování UI: výchozí; 
Národní prostředí: cs-CZ (cs_CZ); Calc: CL

Crash report:
http://crashreport.libreoffice.org/stats/crash_details/61fbc34a-fee5-4bbb-b138-c229f35bbc9c
Comment 1 Xisco Faulí 2018-08-30 13:50:57 UTC
Reproduced in

Version: 6.2.0.0.alpha0+
Build ID: 3bd8316718fdfed454c01a9c4ae6af6beb34437d
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: threaded
Comment 2 Xisco Faulí 2018-08-30 14:27:30 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=00657aef09d854c74fb426a935a3e8b1fc390bb0

author	Caolán McNamara <caolanm@redhat.com>	2017-06-11 20:56:30 +0100
committer	Caolán McNamara <caolanm@redhat.com>	2017-07-21 08:20:50 +0100
commit	00657aef09d854c74fb426a935a3e8b1fc390bb0 (patch)
tree	fd1a9bb264fe15dcc129498e62060ecd256b1ee7
parent	fa987cbb813cfd729fe490f2f1258b7c8d7fb174 (diff)
migrate to boost::gettext

Bisected with: bibisect-linux64-6.0

Adding Cc: to Caolán McNamara
Comment 3 Xisco Faulí 2018-08-30 14:32:06 UTC
Created attachment 144561 [details]
gdb backtrace
Comment 5 Xisco Faulí 2018-08-30 22:57:12 UTC
(In reply to Caolán McNamara from comment #4)
> https://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=7ed402ba648dd0f3de3b0dadebc13403b2c0a620 looks suspect to me

Indeed! it seems 00657aef09d854c74fb426a935a3e8b1fc390bb0 made the macro to crash as well, then it was fixed and the crash was reintroduced with 7ed402ba648dd0f3de3b0dadebc13403b2c0a620.
Sorry for the noise and thank you very much for taking care of it
Comment 6 Commit Notification 2018-08-31 07:28:22 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6fe7b0ae629a258649feb5b8dfc87d6579321587

Resolves: tdf#119607 crash in calling getPropertyState on TextParagraph

It will be available in 6.2.0.

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

Affected users are encouraged to test the fix and report feedback.
Comment 7 Caolán McNamara 2018-08-31 07:29:04 UTC
backport to 6-1 in gerrit
Comment 8 Commit Notification 2018-09-03 14:36:51 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=d3e07a584fc92c548d6356116448e202a2766d11&h=libreoffice-6-1

Resolves: tdf#119607 crash in calling getPropertyState on TextParagraph

It will be available in 6.1.2.

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

Affected users are encouraged to test the fix and report feedback.
Comment 9 Xisco Faulí 2018-09-03 17:55:07 UTC
Verified in

Version: 6.2.0.0.alpha0+
Build ID: 4b5fcd417587cfb9e6d8b61ecb037ab165eeb5b9
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: threaded

@Caolán, Thanks for fixing this!!