Bug 1324905 - [abrt] supertux: lisp::Lisp::get_lisp(): supertux2 killed by SIGSEGV
Summary: [abrt] supertux: lisp::Lisp::get_lisp(): supertux2 killed by SIGSEGV
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: supertux
Version: 24
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: David King
QA Contact: Fedora Extras Quality Assurance
URL: https://retrace.fedoraproject.org/faf...
Whiteboard: abrt_hash:30fa0bda1d0f6646d49c3ad6da3...
: 1325398 1366823 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-04-07 14:36 UTC by cornelis stravers
Modified: 2017-08-08 14:11 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-08 14:11:39 UTC
Type: ---


Attachments (Terms of Use)
File: backtrace (43.52 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: cgroup (242 bytes, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: core_backtrace (4.68 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: dso_list (9.77 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: environ (1.31 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: exploitable (82 bytes, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: limits (1.29 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: maps (125.15 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: mountinfo (3.96 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: namespaces (85 bytes, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: open_fds (780 bytes, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: proc_pid_status (1.10 KB, text/plain)
2016-04-07 14:36 UTC, cornelis stravers
no flags Details
File: var_log_messages (309 bytes, text/plain)
2016-04-07 14:37 UTC, cornelis stravers
no flags Details
Patch to fix crash with empty Lisp expressions (582 bytes, patch)
2016-07-29 03:31 UTC, Jerry James
no flags Details | Diff
Modified spec file for previous patch and bundling squirrel (10.13 KB, text/plain)
2016-07-29 03:32 UTC, Jerry James
no flags Details
Patch to fix crash with empty Lisp expressions (1.01 KB, patch)
2016-07-29 14:16 UTC, Jerry James
no flags Details | Diff

Description cornelis stravers 2016-04-07 14:36:41 UTC
Description of problem:


Version-Release number of selected component:
supertux-0.4.0-4.fc24

Additional info:
reporter:       libreport-2.6.4
backtrace_rating: 4
cmdline:        supertux2
crash_function: lisp::Lisp::get_lisp
executable:     /usr/bin/supertux2
global_pid:     4757
kernel:         4.5.0-0.rc7.git0.2.fc24.x86_64
runlevel:       N 5
type:           CCpp
uid:            1000

Truncated backtrace:
Thread no. 1 (10 frames)
 #0 lisp::Lisp::get_lisp at /usr/src/debug/supertux-0.4.0/src/lisp/lisp.cpp:37
 #1 lisp::Lisp::get<int> at /usr/src/debug/supertux-0.4.0/src/lisp/lisp.hpp:134
 #2 reader_get_layer at /usr/src/debug/supertux-0.4.0/src/util/reader.cpp:31
 #3 SnowParticleSystem::parse at /usr/src/debug/supertux-0.4.0/src/object/snow_particle_system.cpp:80
 #4 Sector::parse_object at /usr/src/debug/supertux-0.4.0/src/supertux/sector.cpp:160
 #5 Sector::parse at /usr/src/debug/supertux-0.4.0/src/supertux/sector.cpp:219
 #6 Level::load at /usr/src/debug/supertux-0.4.0/src/supertux/level.cpp:122
 #7 GameSession::restart_level at /usr/src/debug/supertux-0.4.0/src/supertux/game_session.cpp:126
 #8 GameSession::GameSession at /usr/src/debug/supertux-0.4.0/src/supertux/game_session.cpp:88
 #9 worldmap::WorldMap::update at /usr/src/debug/supertux-0.4.0/src/worldmap/worldmap.cpp:681

Comment 1 cornelis stravers 2016-04-07 14:36:45 UTC
Created attachment 1144758 [details]
File: backtrace

Comment 2 cornelis stravers 2016-04-07 14:36:46 UTC
Created attachment 1144759 [details]
File: cgroup

Comment 3 cornelis stravers 2016-04-07 14:36:47 UTC
Created attachment 1144760 [details]
File: core_backtrace

Comment 4 cornelis stravers 2016-04-07 14:36:49 UTC
Created attachment 1144761 [details]
File: dso_list

Comment 5 cornelis stravers 2016-04-07 14:36:50 UTC
Created attachment 1144762 [details]
File: environ

Comment 6 cornelis stravers 2016-04-07 14:36:51 UTC
Created attachment 1144763 [details]
File: exploitable

Comment 7 cornelis stravers 2016-04-07 14:36:52 UTC
Created attachment 1144764 [details]
File: limits

Comment 8 cornelis stravers 2016-04-07 14:36:54 UTC
Created attachment 1144765 [details]
File: maps

Comment 9 cornelis stravers 2016-04-07 14:36:55 UTC
Created attachment 1144766 [details]
File: mountinfo

Comment 10 cornelis stravers 2016-04-07 14:36:56 UTC
Created attachment 1144767 [details]
File: namespaces

Comment 11 cornelis stravers 2016-04-07 14:36:57 UTC
Created attachment 1144768 [details]
File: open_fds

Comment 12 cornelis stravers 2016-04-07 14:36:59 UTC
Created attachment 1144769 [details]
File: proc_pid_status

Comment 13 cornelis stravers 2016-04-07 14:37:00 UTC
Created attachment 1144770 [details]
File: var_log_messages

Comment 14 Han Han 2016-04-11 15:43:07 UTC
Similar problem has been detected:

Start story mode, get SIGSEGV.

reporter:       libreport-2.6.4
backtrace_rating: 4
cmdline:        supertux2
crash_function: lisp::Lisp::get_lisp
executable:     /usr/bin/supertux2
global_pid:     18570
kernel:         4.5.0-302.fc24.x86_64
package:        supertux-0.4.0-4.fc24
reason:         supertux2 killed by SIGSEGV
runlevel:       N 5
type:           CCpp
uid:            1000

Comment 15 Jos de Kloe 2016-07-09 20:57:32 UTC
confirmed on my machine as well.
When I start from the commandline, and choose story mode I get a segmentation fault:

>supertux2
[SQUIRREL] [DEBUG] Underground state initialized
Segmentation fault (core dumped)
>

on the other hand when I choose "contrib levels" the game seems to work fine, but still suffers from the other unsolved bug #1295185 and will not save its progress.

Affected software version: supertux-0.4.0-4.fc24.x86_64

Comment 16 Jerry James 2016-07-28 04:28:18 UTC
The problem appears to be triggered by level files like /usr/share/supertux2/levels/bonus3/hanging\ roof.stl, which contains this:

    (particles-clouds
    )
    (particles-clouds
    )

The empty body of the particles-clouds forms triggers the bug.  Probably the easiest fix is to patch Sector::parse() in src/supertux/sector.cpp.  The line that reads:

  GameObjectPtr object = parse_object(token, *(iter.lisp()));

should instead do something like this:

  Reader *reader = iter.lisp();
  if (reader) {
    GameObjectPtr object = parse_object(token, *reader);
    if (object) {
      ...
    }
  }

Warning: I have not actually tried this.  This approach may well cause some other bug to be triggered.

Comment 17 Jerry James 2016-07-29 03:31:25 UTC
Created attachment 1185351 [details]
Patch to fix crash with empty Lisp expressions

That approach seems to work.  I went through a couple of the formerly problematic levels with no trouble using the attached patch.  I will attach the spec file I used, too, for reference.

Comment 18 Jerry James 2016-07-29 03:32:01 UTC
Created attachment 1185352 [details]
Modified spec file for previous patch and bundling squirrel

Comment 19 David King 2016-07-29 11:42:15 UTC
(In reply to Jerry James from comment #17)
> Created attachment 1185351 [details]
> Patch to fix crash with empty Lisp expressions

This does not seem to be the correct patch.

Comment 20 Jerry James 2016-07-29 14:16:50 UTC
Created attachment 1185575 [details]
Patch to fix crash with empty Lisp expressions

Oops, no that's the patch just above the correct one in the file chooser.  I must have clicked a little bit too high.  Try this one instead.

Comment 21 Sergey 2016-07-29 16:47:10 UTC
Similar problem has been detected:

run supertux2
setup joystick
run history game mode
then I got these strange crash, have no crashes with these game long play on ubuntu.

reporter:       libreport-2.7.2
backtrace_rating: 4
cmdline:        supertux2
crash_function: lisp::Lisp::get_lisp
executable:     /usr/bin/supertux2
global_pid:     1714
kernel:         4.6.4-301.fc24.x86_64
package:        supertux-0.4.0-4.fc24
pkg_fingerprint: 73BD E983 81B4 6521
pkg_vendor:     Fedora Project
reason:         supertux2 killed by SIGSEGV
runlevel:       N 5
type:           CCpp
uid:            1000

Comment 22 David King 2016-08-05 08:51:06 UTC
(In reply to Jerry James from comment #20)
> Created attachment 1185575 [details]
> Patch to fix crash with empty Lisp expressions
> 
> Oops, no that's the patch just above the correct one in the file chooser.  I
> must have clicked a little bit too high.  Try this one instead.

Thanks! Looking at the upstream git repository, the code in question has changed a bit, so I have no idea if the patch is still relevant to upstream. Are the levels with the empty Lisp expressions definitely wrong, or is it the parsing that is broken (or both)? It would be good to have a plan on fixing the upstream levels and/or code if it is still broken in git.

Comment 23 Jerry James 2016-08-05 14:03:28 UTC
(In reply to David King from comment #22)
> Thanks! Looking at the upstream git repository, the code in question has
> changed a bit, so I have no idea if the patch is still relevant to upstream.
> Are the levels with the empty Lisp expressions definitely wrong, or is it
> the parsing that is broken (or both)? It would be good to have a plan on
> fixing the upstream levels and/or code if it is still broken in git.

My feeling is that even if the level files are bad, the code still shouldn't crash, so I'm going to go with the parsing being broken.  As for how relevant this patch is to upstream, I'm afraid that I simply don't know.  I just ran supertux under a debugger to see what the problem was, and this seemed to me to be the simplest fix for the current code base.  Upstream may have different views on the matter, or may have already addressed the issue in some other way.

Comment 24 Konstantin 2016-08-13 05:48:23 UTC
*** Bug 1366823 has been marked as a duplicate of this bug. ***

Comment 25 David King 2016-08-13 06:58:20 UTC
*** Bug 1325398 has been marked as a duplicate of this bug. ***

Comment 26 Fedora End Of Life 2017-07-25 20:30:12 UTC
This message is a reminder that Fedora 24 is nearing its end of life.
Approximately 2 (two) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 24. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '24'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 24 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 27 Fedora End Of Life 2017-08-08 14:11:39 UTC
Fedora 24 changed to end-of-life (EOL) status on 2017-08-08. Fedora 24 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.