﻿id,summary,reporter,owner,description,type,status,component,version,resolution,keywords,cc,guest,host
7061,Segfault in Fedora 13 guest when accessing 3d tools -> fixed as of 24-Nov-2010 for 4.0 and later only,Noel,,"I am running Fedora 13 x86_64 (Goddard), fully patched, under VirtualBox (PUEL edition) 3.2.4. (r62467). The Host OS is win7, 64-bit. 

{{{
# uname -a
Linux myhost 2.6.33.5-124.fc13.x86_64 #1 SMP Fri Jun 11 09:38:12 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux
}}}

Within Fedora running Gnome, when I select System, Preferences, Desktop Effects, the program /usr/bin/desktop-effects crashes with a segmentation fault. 

This is the backtrace produced by the crash tool Abrt on Fedora:

{{{
[New Thread 2208]
Core was generated by `desktop-effects'.
Program terminated with signal 11, Segmentation fault.
#0  0x00007f47ef671cdb in get_window_size (ctx=0x13f7490, 
    fb=<value optimized out>) at swrast.c:441
441	swrast.c: No such file or directory.
	in swrast.c

Thread 1 (Thread 2208):
#0  0x00007f47ef671cdb in get_window_size (ctx=0x13f7490, 
    fb=<value optimized out>) at swrast.c:441
        buf = 0x1728ef0
        screen = 0x12ac350
        x = 0
        y = 19647264
#1  swrast_check_and_update_window_size (ctx=0x13f7490, 
    fb=<value optimized out>) at swrast.c:451
        width = 54
        height = -2145113757
#2  0x00007f47ef671d5d in driBindContext (ctx=0x13f7490, draw=0x1728ef0, 
    read=0x1728ef0) at swrast.c:616
        mesaCtx = 0x13f7490
        mesaDraw = 0x1728ef0
        mesaRead = 0x1728ef0
#3  0x0000003680224d69 in MakeContextCurrent (dpy=0x124f200, draw=69206022, 
    read=69206022, gc=0x12bcb20) at glxcurrent.c:402
        pdraw = 0x7fff3ff9398c
        pread = <value optimized out>
        oldGC = 0x3680468580
        reply = {type = 6 '\006', unused = 0 '\000', sequenceNumber = 1056, 
          length = 0, contextTag = 1810119199, pad2 = 54, pad3 = 19242488, 
          pad4 = 0, pad5 = 1809976991, pad6 = 54}
        opcode = 153 '\231'
        oldOpcode = 153 '\231'
        bindReturnValue = <value optimized out>
        state = <value optimized out>
#4  0x0000000000403126 in has_hardware_gl (argc=1, argv=0x7fff3ff93c78)
    at desktop-effects.c:1005
        xdisplay = 0x124f200
        renderer = <value optimized out>
        window = 69206022
        attrlist = {4, 8, 1, 9, 1, 10, 1, 5, 0}
        screen = <value optimized out>
        cwa = {background_pixmap = 0, background_pixel = 0, 
          border_pixmap = 0, border_pixel = 0, bit_gravity = 0, 
          win_gravity = 0, backing_store = 0, backing_planes = 0, 
          backing_pixel = 0, save_under = 0, event_mask = 0, 
          do_not_propagate_mask = 0, override_redirect = 0, 
          colormap = 69206021, cursor = 0}
        xscreen = <value optimized out>
        context = 0x12bcb20
        visual = <value optimized out>
        success = 0
#5  main (argc=1, argv=0x7fff3ff93c78) at desktop-effects.c:1064
        app = <value optimized out>
        err = 0x0
From                To                  Syms Read   Shared Object Library
0x0000003673211b30  0x000000367322da28  Yes         /usr/lib64/libgconf-2.so.4
0x0000003680220680  0x000000368024c568  Yes         /usr/lib64/libGL.so.1
0x0000003682a09390  0x0000003682a140e8  Yes         /usr/lib64/libglade-2.0.so.0
0x0000003671a681c0  0x0000003671d0d268  Yes         /usr/lib64/libgtk-x11-2.0.so.0
0x000000367262c950  0x0000003672709048  Yes         /usr/lib64/libxml2.so.2
0x000000366f21d260  0x000000366f27f2a8  Yes         /usr/lib64/libgdk-x11-2.0.so.0
0x00000036712096b0  0x00000036712150f8  Yes         /usr/lib64/libatk-1.0.so.0
0x000000366b619b60  0x000000366b6812c8  Yes         /lib64/libgio-2.0.so.0
0x000000366fe07650  0x000000366fe21348  Yes         /usr/lib64/libpangoft2-1.0.so.0
0x000000366ee05940  0x000000366ee17ba8  Yes         /usr/lib64/libgdk_pixbuf-2.0.so.0
0x000000366e604630  0x000000366e608eb8  Yes         /usr/lib64/libpangocairo-1.0.so.0
0x000000366fa09c50  0x000000366fa5b058  Yes         /usr/lib64/libcairo.so.2
0x000000367020ede0  0x000000367022d768  Yes         /usr/lib64/libpango-1.0.so.0
0x000000366d20c850  0x000000366d2745a8  Yes         /usr/lib64/libfreetype.so.6
0x000000366d605c80  0x000000366d61ff28  Yes         /usr/lib64/libfontconfig.so.1
0x000000366a608d20  0x000000366a632a78  Yes         /lib64/libgobject-2.0.so.0
0x000000366b201080  0x000000366b201fc8  Yes         /lib64/libgmodule-2.0.so.0
0x000000366aa01590  0x000000366aa029f8  Yes         /lib64/libgthread-2.0.so.0
0x0000003668e02140  0x0000003668e055a8  Yes         /lib64/librt.so.1
0x0000003669a155c0  0x0000003669a99d58  Yes         /lib64/libglib-2.0.so.0
0x000000366f600b40  0x000000366f601908  Yes         /usr/lib64/libXcomposite.so.1
0x0000003671601370  0x0000003671604178  Yes         /usr/lib64/libXfixes.so.3
0x000000366be1dd80  0x000000366beab938  Yes         /usr/lib64/libX11.so.6
0x0000003668605640  0x0000003668610e48  Yes         /lib64/libpthread.so.0
0x000000366821e9a0  0x000000366832b9e0  Yes         /lib64/libc.so.6
0x0000003672a27990  0x0000003672a4b6a8  Yes         /usr/lib64/libORBit-2.so.0
0x000000366ae07090  0x000000366ae2e4c8  Yes         /lib64/libdbus-1.so.3
0x000000366ce03580  0x000000366ce0e768  Yes         /usr/lib64/libXext.so.6
0x000000367de00e30  0x000000367de03d08  Yes         /usr/lib64/libXxf86vm.so.1
0x0000003670e00a90  0x0000003670e01638  Yes         /usr/lib64/libXdamage.so.1
0x0000003680a02f90  0x0000003680a07858  Yes         /usr/lib64/libdrm.so.2
0x0000003669203ea0  0x0000003669243fa8  Yes         /lib64/libm.so.6
0x0000003668a00de0  0x0000003668a01998  Yes         /lib64/libdl.so.2
0x0000003669601ef0  0x000000366960d228  Yes         /lib64/libz.so.1
0x0000003670a018c0  0x0000003670a07f58  Yes         /usr/lib64/libXrender.so.1
0x0000003672200a20  0x0000003672201508  Yes         /usr/lib64/libXinerama.so.1
0x000000366de01eb0  0x000000366de0c608  Yes         /usr/lib64/libXi.so.6
0x000000366ea01720  0x000000366ea06828  Yes         /usr/lib64/libXrandr.so.2
0x0000003670602880  0x0000003670607678  Yes         /usr/lib64/libXcursor.so.1
0x000000366a2038c0  0x000000366a212528  Yes         /lib64/libresolv.so.2
0x0000003669e05550  0x0000003669e15038  Yes         /lib64/libselinux.so.1
0x000000366da04830  0x000000366da1e7a8  Yes         /usr/lib64/libpng12.so.0
0x000000366e207230  0x000000366e251e78  Yes         /usr/lib64/libpixman-1.so.0
0x000000366c603b70  0x000000366c61ca08  Yes         /lib64/libexpat.so.1
0x0000003667e00af0  0x0000003667e18934  Yes         /lib64/ld-linux-x86-64.so.2
0x000000366c208650  0x000000366c213898  Yes         /usr/lib64/libxcb.so.1
0x000000366ba00dd0  0x000000366ba01b68  Yes         /usr/lib64/libXau.so.6
0x00007f47f1080110  0x00007f47f1088278  Yes         /lib64/libnss_files.so.2
0x00007f47f0e6d910  0x00007f47f0e7b0d8  Yes         /usr/lib64/gtk-2.0/2.10.0/engines/libglide.so
0x00007f47f0c69620  0x00007f47f0c69e08  Yes         /usr/lib64/gtk-2.0/modules/libpk-gtk-module.so
0x000000366ca08f70  0x000000366ca194a8  Yes         /usr/lib64/libdbus-glib-1.so.2
0x00007f47f0a63fb0  0x00007f47f0a661e8  Yes         /usr/lib64/gtk-2.0/modules/libcanberra-gtk-module.so
0x0000003681201c60  0x00000036812030a8  Yes         /usr/lib64/libcanberra-gtk.so.0
0x0000003680603280  0x000000368060c318  Yes         /usr/lib64/libcanberra.so.0
0x000000367e601fa0  0x000000367e605fd8  Yes         /usr/lib64/libvorbisfile.so.3
0x000000367ca03700  0x000000367ca1a718  Yes         /usr/lib64/libvorbis.so.0
0x000000367be018a0  0x000000367be03bb8  Yes         /usr/lib64/libogg.so.0
0x000000367c601e30  0x000000367c609ca8  Yes         /usr/lib64/libtdb.so.1
0x000000367a202370  0x000000367a206758  Yes         /usr/lib64/libltdl.so.7
0x00007f47f08f9e30  0x00007f47f0928958  Yes (*)     /usr/lib64/dri/vboxvideo_dri.so
0x00007f47f07a60d0  0x00007f47f07b8388  Yes (*)     /usr/lib64/VBoxOGLcrutil.so
0x00007f47f0532d90  0x00007f47f0635298  Yes (*)     /usr/lib64/VBoxOGLpackspu.so
0x00007f47f04056e0  0x00007f47f040ae18  Yes (*)     /usr/lib64/VBoxOGLerrorspu.so
0x00007f47efcba920  0x00007f47efd2b838  Yes (*)     /usr/lib64/VBoxOGLfeedbackspu.so
0x00007f47efba2660  0x00007f47efba68a8  Yes (*)     /usr/lib64/VBoxOGLpassthroughspu.so
0x00007f47ef670540  0x00007f47ef7b86d8  Yes         /usr/lib64/dri/swrast_dri.so
(*): Shared library is missing debugging information.
$1 = 0x0
$2 = 0x0
rax            0x0	0
rbx            0x1728ef0	24284912
rcx            0x7fff3ff9398c	140734266685836
rdx            0x7fff3ff93980	140734266685824
rsi            0x7fff3ff93984	140734266685828
rdi            0x1728ef0	24284912
rbp            0x13f7490	0x13f7490
rsp            0x7fff3ff93980	0x7fff3ff93980
r8             0x7fff3ff93988	140734266685832
r9             0x1728eb0	24284848
r10            0x18	24
r11            0x7f47ef671d0c	139946935917836
r12            0x1728ef0	24284912
r13            0x4200006	69206022
r14            0x4200006	69206022
r15            0x99	153
rip            0x7f47ef671cdb	0x7f47ef671cdb <swrast_check_and_update_window_size+51>
eflags         0x10202	[ IF RF ]
cs             0x33	51
ss             0x2b	43
ds             0x0	0
es             0x0	0
fs             0x0	0
gs             0x0	0
Dump of assembler code for function swrast_check_and_update_window_size:
   0x00007f47ef671ca8 <+0>:	push   %rbp
   0x00007f47ef671ca9 <+1>:	mov    %rdi,%rbp
   0x00007f47ef671cac <+4>:	push   %rbx
   0x00007f47ef671cad <+5>:	mov    %rsi,%rbx
   0x00007f47ef671cb0 <+8>:	mov    %rbx,%rdi
   0x00007f47ef671cb3 <+11>:	sub    $0x18,%rsp
   0x00007f47ef671cb7 <+15>:	mov    0x438(%rsi),%rax
   0x00007f47ef671cbe <+22>:	mov    0x430(%rbx),%r9
   0x00007f47ef671cc5 <+29>:	mov    %rsp,%rdx
   0x00007f47ef671cc8 <+32>:	lea    0xc(%rsp),%rcx
   0x00007f47ef671ccd <+37>:	lea    0x4(%rsp),%rsi
   0x00007f47ef671cd2 <+42>:	lea    0x8(%rsp),%r8
   0x00007f47ef671cd7 <+47>:	mov    0x10(%rax),%rax
=> 0x00007f47ef671cdb <+51>:	callq  *0x10(%rax)
   0x00007f47ef671cde <+54>:	mov    0xc(%rsp),%edx
   0x00007f47ef671ce2 <+58>:	cmp    %edx,0x114(%rbx)
   0x00007f47ef671ce8 <+64>:	jne    0x7f47ef671cf6 <swrast_check_and_update_window_size+78>
   0x00007f47ef671cea <+66>:	mov    0x118(%rbx),%eax
   0x00007f47ef671cf0 <+72>:	cmp    0x8(%rsp),%eax
   0x00007f47ef671cf4 <+76>:	je     0x7f47ef671d05 <swrast_check_and_update_window_size+93>
   0x00007f47ef671cf6 <+78>:	mov    0x8(%rsp),%ecx
   0x00007f47ef671cfa <+82>:	mov    %rbx,%rsi
   0x00007f47ef671cfd <+85>:	mov    %rbp,%rdi
   0x00007f47ef671d00 <+88>:	callq  0x7f47ef695dda <_mesa_resize_framebuffer>
   0x00007f47ef671d05 <+93>:	add    $0x18,%rsp
   0x00007f47ef671d09 <+97>:	pop    %rbx
   0x00007f47ef671d0a <+98>:	pop    %rbp
   0x00007f47ef671d0b <+99>:	retq   
End of assembler dump.
}}}

I initially reported the issue to Fedora but their developers say that the problem lies within the display drivers used by VirtualBox. The Bugzilla ticket is here: https://bugzilla.redhat.com/show_bug.cgi?id=603569

After I installed Fedora 13 I patched it, then mounted the Guest Additions DVD and ran VBoxLinuxAdditions-amd64.run. It completed successfully.

{{{
# ./VBoxLinuxAdditions-amd64.run 
Verifying archive integrity... All good.
Uncompressing VirtualBox 3.2.4 Guest Additions for Linux........
VirtualBox Guest Additions installer
Removing installed version 3.2.4 of VirtualBox Guest Additions...
Building the VirtualBox Guest Additions kernel modules
Building the main Guest Additions module                   [  OK  ]
Building the shared folder support module                  [  OK  ]
Building the OpenGL support module                         [  OK  ]
Doing non-kernel setup of the Guest Additions              [  OK  ]
You should restart your guest to make sure the new modules are actually used

Installing the Window System drivers
Installing X.Org Server 1.8 modules                        [  OK  ]
Setting up the Window System to use the Guest Additions    [  OK  ]
The following X.Org/XFree86 configuration files were originally generated by
the VirtualBox Guest Additions and were not modified:

  /etc/X11/xorg.conf

You may need to restart the hal service and the Window System (or just restart
the guest system) to enable the Guest Additions.

Installing graphics libraries and desktop services componen[  OK  ]
}}}

I can also causes a segmentation fault by running opengl tools like glxinfo and glxgears. 

The VM is allocated 128MB of RAM for video memory and 3d acceleration is enabled.

{{{
# glxinfo
name of display: :0.0
Segmentation fault (core dumped)

# gdb /usr/bin/glxinfo core.5998 
GNU gdb (GDB) Fedora (7.1-26.fc13)
Copyright (C) 2010 Free Software Foundation, Inc.
[...]

Core was generated by `glxinfo'.
Program terminated with signal 11, Segmentation fault.
#0  0x00007f69a57adcdb in get_window_size (ctx=0x1033770, fb=<value optimized out>)
    at swrast.c:441
441	    screen->swrast_loader->getDrawableInfo(buf,

(gdb) bt
#0  0x00007f69a57adcdb in get_window_size (ctx=0x1033770, fb=<value optimized out>)
    at swrast.c:441
#1  swrast_check_and_update_window_size (ctx=0x1033770, fb=<value optimized out>) at swrast.c:451
#2  0x00007f69a57add5d in driBindContext (ctx=0x1033770, draw=0x13651b0, read=0x13651b0)
    at swrast.c:616
#3  0x0000003680224d69 in MakeContextCurrent (dpy=0xedb010, draw=88080388, read=88080388, 
    gc=0xef8200) at glxcurrent.c:402
#4  0x0000000000401ae9 in print_screen_info (dpy=0xedb010, scrnum=0, allowDirect=1, 
    limits=0 '\000') at glxinfo.c:482
#5  0x0000000000402943 in main (argc=1, argv=0x7fff7065fe28) at glxinfo.c:1181

}}}

I cannot think of anything else to add. I will be happy to provide more information but please bear in mind that my timezone is NZST, GMT+12.
",defect,closed,3D support,VirtualBox 3.2.4,fixed,vboxvideo swrast.c get_window_size,,Linux,Windows
