Download it now!
Bug 96243 - Crashes when view path is incorrect
Summary: Crashes when view path is incorrect
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
5.1.0.0.beta1
Hardware: All All
: medium normal
Assignee: David Tardon
URL:
Whiteboard: target:5.2.0 target:5.1.0.1
Keywords:
Depends on:
Blocks:
 
Reported: 2015-12-04 12:27 UTC by Bastien Nocera
Modified: 2016-10-25 19:11 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bastien Nocera 2015-12-04 12:27:59 UTC
Using http://koji.fedoraproject.org/koji/buildinfo?buildID=703072

$ cat test.js 
#!/usr/bin/gjs

const Gtk = imports.gi.Gtk;
const LOKDocView = imports.gi.LOKDocView;

Gtk.init(null);

let view = LOKDocView.View.new("/path/that/doesnt/exist", null, null);

$ GI_TYPELIB_PATH=$GI_TYPELIB_PATH:/usr/lib64/libreoffice/girepository-1.0/ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64/libreoffice/program/ gjs test.js 

failed to open library '/path/that/doesnt/exit/libmergedlo.so': /path/that/doesnt/exit/libmergedlo.so: cannot open shared object file: No such file or directory
failed to find hook in library '(null)'
Segmentation fault (core dumped)

The call should fail gracefully instead.
Comment 1 Commit Notification 2015-12-07 12:15:11 UTC
David Tardon committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=7f73ea2e3975b305e09467eb7980a3d01cd37de9

tdf#96243 don't crash if LibO install. wasn't found

It will be available in 5.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 2 Commit Notification 2015-12-07 12:15:17 UTC
David Tardon committed a patch related to this issue.
It has been pushed to "libreoffice-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=125382803df6502e467cb25b6ee70c24d5f4dfc0&h=libreoffice-5-1

tdf#96243 don't crash if LibO install. wasn't found

It will be available in 5.1.0.1.

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.