Bug 116586 - Crash with Hungarian spell checker in 6.0 debug build
Summary: Crash with Hungarian spell checker in 6.0 debug build
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Linguistic (show other bugs)
Version:
(earliest affected)
6.0.3.1 rc
Hardware: All All
: medium major
Assignee: László Németh
URL:
Whiteboard: target:6.0.3 target:6.1.0
Keywords: haveBacktrace
Depends on:
Blocks: Spell-Checking Crash-Assert
  Show dependency treegraph
 
Reported: 2018-03-23 13:38 UTC by Aron Budea
Modified: 2018-04-03 07:11 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Backtrace (14.27 KB, text/plain)
2018-03-23 13:38 UTC, Aron Budea
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aron Budea 2018-03-23 13:38:40 UTC
Created attachment 140828 [details]
Backtrace

Prerequisite:
With a debug build of libreoffice-6-0 branch (I was at 90fb652ebbc4b16ae5001140076f52209e913345), have Hungarian spell checker installed (ie. hunspell-hu in Ubuntu), or copy the content of 'hu_HU' from dictionaries repo into 'instdir/share/extensions/dict-hu'.
I assume debug libstdc++ packages are also needed.

Repro:
Open a Hungarian document eg. 'sw/qa/extras/uiwriter/data/commented-word.odt', or set document language to Hungarian, and start typing.

=> Crash.
(the menioned document is for a unit test, so if Hungarian spell checker is installed, the respective unit test will fail)

The crash is in Hunspell (or rather in C++ STD library), this is the relevant part of the backtrace (attaching the whole thing):

#2  0x00007ffff6a564e3 in __gnu_debug::_Error_formatter::_M_error() const () at /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#3  0x00007fffbf28f9a4 in std::binary_search<unsigned short*, unsigned short>(unsigned short*, unsigned short*, unsigned short const&) (__first=0x555557420e00, __last=0x555557420e2c, __val=@0x55555741a9dc: 119) at /usr/include/c++/7/bits/stl_algo.h:2254
#4  0x00007fffbf2e92c2 in HashMgr::remove_forbidden_flag(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (this=0x55555741a9c0, word="élethalálharc") at hashmgr.cxx:509

There's also this message on the console:
/usr/include/c++/7/bits/stl_algo.h:2254:
Error: elements in iterator range [__first, __last) are not partitioned by 
the value __val.


There is no crash in a debug master build, so I have to close this as WORKSFORME right away.
László, is there a chance you could investigate what is wrong here?
Comment 1 László Németh 2018-03-23 15:23:17 UTC
@Áron: yes, I started to check it. Could you confirm, that the crash occurs only with the enabled Hungarian personal dictionary AkH11 (old orthography)?
Comment 2 Aron Budea 2018-03-23 17:01:10 UTC
@László: thanks for pointing to that, indeed there is no crash if hu_AkH11 is disabled among user-defined dictionaries.
Comment 3 Aron Budea 2018-03-26 17:23:32 UTC
Actually, this occurs in master with the mentioned dictionary enabled, so this issue wasn't resolved there, either.
@László, since you have a patch in gerrit, let me assign the bug report to you, thanks for working on this!
Comment 4 Commit Notification 2018-03-27 06:25:31 UTC
László Németh committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2d08125e2ad971ac81ba8ca7a0af616e768372e6&h=libreoffice-6-0

tdf#116586 hu_AkH11 is not a default personal dictionary

It will be available in 6.0.4.

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 5 Commit Notification 2018-03-27 09:50:11 UTC
László Németh committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

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

tdf#116586 fix LibreOffice crash by Hungarian personal dictionary

It will be available in 6.0.4.

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 6 Commit Notification 2018-03-27 10:48:58 UTC
László Németh committed a patch related to this issue.
It has been pushed to "libreoffice-6-0-3":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=941527edd3345a657e0af458c1a9fad8247db90b&h=libreoffice-6-0-3

tdf#116586 hu_AkH11 is not a default personal dictionary

It will be available in 6.0.3.

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 Commit Notification 2018-03-29 10:54:27 UTC
László Németh committed a patch related to this issue.
It has been pushed to "libreoffice-6-0-3":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=e621e1070fb096f0904bd8f43d906d7a4636c246&h=libreoffice-6-0-3

tdf#116586 fix LibreOffice crash by Hungarian personal dictionary

It will be available in 6.0.3.

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 8 Commit Notification 2018-04-03 07:09:26 UTC
László Németh committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=18ce9d80dc1ba0262e145a015526da7c0851a74b

tdf#116586 fix LibreOffice crash by Hungarian personal dictionary

It will be available in 6.1.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.