project-navigation
Personal tools

Author Topic: Segmentation fault  (Read 4310 times)

hades

  • Guest
Segmentation fault
« on: February 27, 2008, 06:10:52 pm »
revision 15343

hades@hadez:/opt/game/ufoai/share/ufoai$ ./ufo

---- filesystem initialization -----
Adding game dir: ./base
Added packfile ./base/0base.pk3 (4 files)
Added packfile ./base/0maps.pk3 (17 files)
Added packfile ./base/0materials.pk3 (6 files)
Added packfile ./base/0media.pk3 (11 files)
Added packfile ./base/0models.pk3 (1342 files)
Added packfile ./base/0music.pk3 (37 files)
Added packfile ./base/0pics.pk3 (1691 files)
Added packfile ./base/0snd.pk3 (169 files)
Added packfile ./base/0ufos.pk3 (74 files)
using /home/hades/.ufoai/2.3-dev/base for writing
Adding game dir: /home/hades/.ufoai/2.3-dev/base
execing default.cfg
execing config.cfg
execing keys.cfg

----- network initialization -------
libcurl/7.15.5 OpenSSL/0.9.8c zlib/1.2.3 libidn/0.6.5 initialized.

------ server initialization -------

----- console initialization -------
loaded console history commands: 0
Console initialized.

------- video initialization -------
SDL version: 1.2.11
I: desktop depth: 32bpp
I: video memory: 0
I: video driver: x11
I: setting mode 6: 1024x768 (fullscreen: no)
I: got 8 bits of stencil
I: got 24 bits of depth buffer
I: got double buffer
I: got 8 bits for red
I: got 8 bits for green
I: got 8 bits for blue
I: got 8 bits for alpha
GL_VENDOR: VIA Technology
GL_RENDERER: Mesa DRI UniChrome 20060710
GL_VERSION: 1.2 Mesa 6.5.1
GL_EXTENSIONS: GL_ARB_imaging GL_ARB_multisample GL_ARB_multitexture GL_ARB_point_parameters GL_ARB_texture_env_add GL_ARB_texture_env_combine GL_ARB_texture_mirrored_repeat GL_ARB_transpose_matrix GL_ARB_window_pos GL_EXT_abgr GL_EXT_bgra GL_EXT_blend_color GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_clip_volume_hint GL_EXT_compiled_vertex_array GL_EXT_convolution GL_EXT_copy_texture GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_histogram GL_EXT_packed_pixels GL_EXT_point_parameters GL_EXT_polygon_offset GL_EXT_rescale_normal GL_EXT_secondary_color GL_EXT_separate_specular_color GL_EXT_stencil_wrap GL_EXT_subtexture GL_EXT_texture GL_EXT_texture3D GL_EXT_texture_edge_clamp GL_EXT_texture_env_add GL_EXT_texture_env_combine GL_EXT_texture_lod_bias GL_EXT_texture_object GL_EXT_vertex_array GL_APPLE_packed_pixels GL_IBM_rasterpos_clip GL_IBM_texture_mirrored_repeat GL_MESA_window_pos GL_NV_blend_square GL_NV_light_max_exponent GL_NV_texgen_reflection GL_OES_read_format GL_SGI_color_matrix GL_SGI_color_table GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod
GL_ARB_texture_compression not found
GL_EXT_texture_filter_anisotropic not found
using GL_EXT_texture_lod_bias
GL_ARB_fragment_program not found
GL_ARB_shading_language_100 not found
GL_ARB_vertex_buffer_object not found
max texture units: 2
max texture size: detected 512
SDL_ttf version 2.0.8 - we need at least 2.0.7

------- sound initialization -------
SDL_mixer version: 1.2.6
... audio rate: 44100
... audio channels: 2
... driver: 'alsa'

------- input initialization -------
0 possible joysticks
no joystick found.

--- save subsystem initialization --
added size subsystem (check ff)
added base subsystem (check 0)
added campaign subsystem (check 1)
added hospital subsystem (check 2)
added market subsystem (check 3)
added research subsystem (check 4)
added employee subsystem (check 5)
added aliencont subsystem (check 6)
added production subsystem (check 7)
added aircraft subsystem (check 8)
added messagesystem subsystem (check 9)
added stats subsystem (check a)
added nations subsystem (check b)
added transfer subsystem (check c)

----------- parse scripts ----------
Shared Client/Server Info loaded
... 99 items parsed
... 31 damage types parsed
... 55 map definitions parsed
... 26 equipment definitions parsed
... 10 inventory definitions parsed
... 22 team definitions parsed
music change to van_theme (from PsymongN3)
S_Music_Start: Playing music: 'music/van_theme'
CL_LanguageInit()... language settings are stored in configuration: ru
91 static models loaded
...uploaded 0 shaders
====== UFO Initialized ======

Switch grab input off
Changing to Singleplayer
Global data loaded - size 5404856 bytes
...techs: 172
...buildings: 22
...ranks: 16
...nations: 8

Changing to Singleplayer
Sanity check for script data
...buildings ok
...tech ok
...aircraft ok
...menu ok
music change to van_geoscape (from van_theme)
Changing to Singleplayer
Save user settings to /home/hades/.ufoai/2.3-dev/base/config.cfg
Segmentation fault

hades

  • Guest
Re: Segmentation fault
« Reply #1 on: February 27, 2008, 07:18:40 pm »
------- input initialization -------
0 possible joysticks
no joystick found.

--- save subsystem initialization --
added size subsystem (check ff)
added base subsystem (check 0)
added campaign subsystem (check 1)
added hospital subsystem (check 2)
added market subsystem (check 3)
added research subsystem (check 4)
added employee subsystem (check 5)
added aliencont subsystem (check 6)
added production subsystem (check 7)
added aircraft subsystem (check 8)
added messagesystem subsystem (check 9)
added stats subsystem (check a)
added nations subsystem (check b)
added transfer subsystem (check c)

----------- parse scripts ----------
Buffer too small: src/common/scripts.c: 245 (nfo))
Buffer too small: src/common/scripts.c: 245 (e info))
Buffer too small: src/common/scripts.c: 255 (ета)
Buffer too small: src/common/scripts.c: 255 (и)
Shared Client/Server Info loaded
... 99 items parsed
... 31 damage types parsed
... 55 map definitions parsed
... 26 equipment definitions parsed
... 10 inventory definitions parsed
... 22 team definitions parsed
music change to van_theme (from PsymongN3)
S_Music_Start: Playing music: 'music/van_theme'
==9179==
==9179== Thread 1:
==9179== Invalid read of size 4
==9179==    at 0x50261AB: viaSwapOutWork (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5027128: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5028552: viaCopyBuffer (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5022B1A: viaSwapBuffers (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x501E91E: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x4F9E0ED: glXSwapBuffers (in /usr/lib/libGL.so.1.2)
==9179==    by 0x441FE24: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x441415B: SDL_GL_SwapBuffers (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x811D748: R_EndFrame (r_main.c:346)
==9179==    by 0x80B7A04: SCR_DrawPrecacheScreen (cl_screen.c:108)
==9179==    by 0x8095C0F: CL_PrecacheModels (cl_main.c:1589)
==9179==    by 0x8095C71: CL_InitAfter (cl_main.c:1625)
==9179==  Address 0x49E4C5C is 20 bytes inside a block of size 40 free'd
==9179==    at 0x401CFA5: free (vg_replace_malloc.c:233)
==9179==    by 0x50802BC: _mesa_free (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50245A5: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5025929: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5026195: viaSwapOutWork (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5027128: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5028552: viaCopyBuffer (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5022B1A: viaSwapBuffers (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x501E91E: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x4F9E0ED: glXSwapBuffers (in /usr/lib/libGL.so.1.2)
==9179==    by 0x441FE24: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x441415B: SDL_GL_SwapBuffers (in /usr/lib/libSDL-1.2.so.0.11.0)
CL_LanguageInit()... language settings are stored in configuration: ru
91 static models loaded
...uploaded 0 shaders
====== UFO Initialized ======

Switch grab input off
==9179==
==9179== Conditional jump or move depends on uninitialised value(s)
==9179==    at 0x441EA87: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x441F3DA: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43ED9F4: SDL_PumpEvents (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43EDEF6: SDL_PollEvent (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x8087BC6: IN_Frame (cl_input.c:1553)
==9179==    by 0x8097B7D: CL_Frame (cl_main.c:2370)
==9179==    by 0x80EA422: tick_timer (common.c:922)
==9179==    by 0x80EA676: Qcommon_Frame (common.c:1003)
==9179==    by 0x81279E2: main (linux_main.c:102)
==9179==
==9179== Conditional jump or move depends on uninitialised value(s)
==9179==    at 0x441EAA3: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x441F3DA: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43ED9F4: SDL_PumpEvents (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43EDEF6: SDL_PollEvent (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x8087BC6: IN_Frame (cl_input.c:1553)
==9179==    by 0x8097B7D: CL_Frame (cl_main.c:2370)
==9179==    by 0x80EA422: tick_timer (common.c:922)
==9179==    by 0x80EA676: Qcommon_Frame (common.c:1003)
==9179==    by 0x81279E2: main (linux_main.c:102)
==9179==
==9179== Invalid read of size 4
==9179==    at 0x50261AB: viaSwapOutWork (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50271FD: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50277F8: viaWaitIdle (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x502DB40: viaSpanRenderStart (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x510D17A: _swrast_render_start (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5146767: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50288AF: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50C53EE: _tnl_run_pipeline (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50320DF: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50F3174: _tnl_flush_vtx (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50EBB3B: _tnl_FlushVertices (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5173159: _mesa_set_enable (in /usr/lib/dri/unichrome_dri.so)
==9179==  Address 0x18E0AE3C is 20 bytes inside a block of size 40 free'd
==9179==    at 0x401CFA5: free (vg_replace_malloc.c:233)
==9179==    by 0x50802BC: _mesa_free (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50245A5: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5025929: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5026195: viaSwapOutWork (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50271FD: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50277F8: viaWaitIdle (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x502DB40: viaSpanRenderStart (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x510D17A: _swrast_render_start (in /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x5146767: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50288AF: (within /usr/lib/dri/unichrome_dri.so)
==9179==    by 0x50C53EE: _tnl_run_pipeline (in /usr/lib/dri/unichrome_dri.so)
Changing to Singleplayer
Global data loaded - size 5404856 bytes
...techs: 172
...buildings: 22
...ranks: 16
...nations: 8

Save user settings to /home/hades/.ufoai/2.3-dev/base/config.cfg
==9179==
==9179== Syscall param ioctl(arg) contains uninitialised byte(s)
==9179==    at 0x4000792: (within /lib/ld-2.3.6.so)
==9179==    by 0x46FF101: snd_pcm_drain (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x441A3F9: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F55: SDL_AudioQuit (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E842B: SDL_QuitSubSystem (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F7D: SDL_CloseAudio (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x437A1B2: Mix_CloseAudio (in /usr/lib/libSDL_mixer-1.2.so.0.2.4)
==9179==    by 0x80BA340: S_Shutdown (cl_sound.c:737)
==9179==    by 0x8097F19: CL_Shutdown (cl_main.c:2538)
==9179==    by 0x8127CA2: Sys_Error (unix_main.c:73)
==9179==    by 0x807D028: E_GetHiredEmployee (cl_employee.c:430)
==9179==    by 0x807D1A0: E_GetHiredCharacter (cl_employee.c:487)
==9179==
==9179== Syscall param ioctl(arg) contains uninitialised byte(s)
==9179==    at 0x4000792: (within /lib/ld-2.3.6.so)
==9179==    by 0x46FF1A1: snd_pcm_drop (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x47066E4: snd_pcm_close (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x441A409: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F55: SDL_AudioQuit (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E842B: SDL_QuitSubSystem (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F7D: SDL_CloseAudio (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x437A1B2: Mix_CloseAudio (in /usr/lib/libSDL_mixer-1.2.so.0.2.4)
==9179==    by 0x80BA340: S_Shutdown (cl_sound.c:737)
==9179==    by 0x8097F19: CL_Shutdown (cl_main.c:2538)
==9179==    by 0x8127CA2: Sys_Error (unix_main.c:73)
==9179==    by 0x807D028: E_GetHiredEmployee (cl_employee.c:430)
==9179==
==9179== Syscall param ioctl(arg) contains uninitialised byte(s)
==9179==    at 0x4000792: (within /lib/ld-2.3.6.so)
==9179==    by 0x4705B0C: snd_pcm_hw_free (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x4721B8C: (within /usr/lib/libasound.so.2.0.0)
==9179==    by 0x4705B0C: snd_pcm_hw_free (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x47066EC: snd_pcm_close (in /usr/lib/libasound.so.2.0.0)
==9179==    by 0x441A409: (within /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F55: SDL_AudioQuit (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E842B: SDL_QuitSubSystem (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x43E8F7D: SDL_CloseAudio (in /usr/lib/libSDL-1.2.so.0.11.0)
==9179==    by 0x437A1B2: Mix_CloseAudio (in /usr/lib/libSDL_mixer-1.2.so.0.2.4)
==9179==    by 0x80BA340: S_Shutdown (cl_sound.c:737)
==9179==    by 0x8097F19: CL_Shutdown (cl_main.c:2538)
Error: Try to get the 1th employee - but you only have 0 hired

==9179==
==9179== ERROR SUMMARY: 746 errors from 37 contexts (suppressed: 73 from 1)
==9179== malloc/free: in use at exit: 115,586 bytes in 3,694 blocks.
==9179== malloc/free: 145,032 allocs, 141,338 frees, 284,808,732 bytes allocated.
==9179== For counts of detected errors, rerun with: -v
==9179== searching for pointers to 3,694 not-freed blocks.
==9179== checked 261,972,764 bytes.
==9179==
==9179== LEAK SUMMARY:
==9179==    definitely lost: 4,687 bytes in 167 blocks.
==9179==      possibly lost: 27,604 bytes in 769 blocks.
==9179==    still reachable: 83,295 bytes in 2,758 blocks.
==9179==         suppressed: 0 bytes in 0 blocks.
==9179== Use --leak-check=full to see details of leaked memory.

Offline geever

  • Project Coder
  • PHALANX Commander
  • ***
  • Posts: 2561
    • View Profile
Re: Segmentation fault
« Reply #2 on: February 27, 2008, 07:26:12 pm »
Nice, but you should put it in the BugTracker:
https://sourceforge.net/tracker/?group_id=157793&atid=805242

Also a backtrace log could help the developers fixing it. 4 more info see:
http://ufoai.ninex.info/wiki/index.php/Debugging

geever