GNOME Bugzilla – Bug 552777
[ruler.py] BadAlloc error with big sources
Last modified: 2008-10-09 06:58:08 UTC
Trying to put two AVI files into the advanced timeline. Shortly after dropping the second file in Pitivi crash with the following going out to the console: $ pitivi Context 1 created GL_VERSION: 2.1.2 NVIDIA 173.14.12 GLEW_VERSION: 1.5.0 GL_SHADING_LANGUAGE_VERSION: 1.20 NVIDIA via Cg compiler GL_VENDOR: NVIDIA Corporation GL_RENDERER: GeForce 8400M G/PCI/SSE2 Context 1 initialized gl mainLoop started Context 1, ARB_fragment_shader supported: yes Context 1, EXT_framebuffer_object supported: yes texture pool insert: 320x240 texture pool size: 1 ** (pitivi:27687): WARNING **: Unknown codec ID 86022, please add here (pitivi:27687): GStreamer-CRITICAL **: Trying to dispose element fakesink8, but it is not in the NULL state. You need to explicitly set elements to the NULL state before dropping the final reference, to allow them to clean up. Context 1 destroyed gl mainLoop exited gl thread joined Context 1 created GL_VERSION: 2.1.2 NVIDIA 173.14.12 GLEW_VERSION: 1.5.0 GL_SHADING_LANGUAGE_VERSION: 1.20 NVIDIA via Cg compiler GL_VENDOR: NVIDIA Corporation GL_RENDERER: GeForce 8400M G/PCI/SSE2 Context 1 initialized gl mainLoop started Context 1, ARB_fragment_shader supported: yes Context 1, EXT_framebuffer_object supported: yes timeout reached in idle func timeout reached in idle func timeout reached in idle func timeout reached in idle func timeout reached in idle func texture pool insert: 352x240 texture pool size: 1 Gdk-ERROR **: The program 'pitivi' received an X Window System error. This probably reflects a bug in the program. The error was 'BadAlloc (insufficient resources for operation)'. (Details: serial 39546 error_code 11 request_code 53 minor_code 0) (Note to programmers: normally, X errors are reported asynchronously; that is, you will receive the error a while after causing it. To debug your program, run it with the --sync command line option to change this behavior. You can then get a meaningful backtrace from your debugger if you break on the gdk_x_error() function.) aborting... Locking assertion failure. Backtrace: #0 /usr/lib64/libxcb-xlib.so.0 [0x387b20097c] #1 /usr/lib64/libxcb-xlib.so.0(xcb_xlib_lock+0x17) [0x387b200af7] #2 /usr/lib64/libX11.so.6 [0x387ba4c610] #3 /usr/lib64/libX11.so.6(XUngrabPointer+0x1a) [0x387ba4291a] #4 /usr/lib64/libgdk-x11-2.0.so.0(gdk_display_pointer_ungrab+0xc8) [0x3d87a4c000] #5 /usr/lib64/libgdk-x11-2.0.so.0(gdk_pointer_ungrab+0x1b) [0x3d87a1d615] #6 /usr/lib64/gtk-2.0/modules/libgnomebreakpad.so [0x2ddf69b] #7 /lib64/libpthread.so.0 [0x3879a0ed30] #8 /lib64/libglib-2.0.so.0(g_logv+0x1f4) [0x3d84e41604] #9 /lib64/libglib-2.0.so.0(g_log+0x83) [0x3d84e41973] #10 /usr/lib64/libgdk-x11-2.0.so.0 [0x3d87a6fa59] #11 /usr/lib64/libX11.so.6(_XError+0xf4) [0x387ba45524] #12 /usr/lib64/libX11.so.6 [0x387ba4cf5f] #13 /usr/lib64/libX11.so.6(_XEventsQueued+0x36) [0x387ba4d806] #14 /usr/lib64/libX11.so.6(XFlush+0x1a) [0x387ba24d8a] #15 /usr/lib64/libgdk-x11-2.0.so.0(gdk_display_flush+0xa5) [0x3d87a4c457] #16 /usr/lib64/libgdk-x11-2.0.so.0 [0x3d87a3fb70] #17 /usr/lib64/libgdk-x11-2.0.so.0(gdk_window_process_all_updates+0x10f) [0x3d87a3fc9d] #18 /usr/lib64/libgtk-x11-2.0.so.0 [0x3d872c56c2] #19 /usr/lib64/libgdk-x11-2.0.so.0 [0x3d87a1bacd] (process:27687): Gdk-ERROR (recursed) **: The program 'pitivi' received an X Window System error. This probably reflects a bug in the program. The error was 'BadDrawable (invalid Pixmap or Window parameter)'. (Details: serial 39547 error_code 9 request_code 151 minor_code 4) (Note to programmers: normally, X errors are reported asynchronously; that is, you will receive the error a while after causing it. To debug your program, run it with the --sync command line option to change this behavior. You can then get a meaningful backtrace from your debugger if you break on the gdk_x_error() function.) aborting... Multiple segmentation faults occurred; can't display error dialog
How big were those files ? In duration I mean.
Reproduced it here with a 1h24m video.
It's caused in fact by the ruler's pixmap.
The problem is due to ruler.pixmap (used for double buffering) which we try to create with the *full* size corresponding to the composition's duration. What we should do to have the best of both worlds, is to keep self.pixmap, but instead of creating it for the whole duration, create it for a smaller region. Maybe twice the visible area, and when we expose outside of that area, we re-create it (centered on the new middle).
2008-10-09 Edward Hervey <bilboed@gmail.com> * pitivi/ui/ruler.py: (ScaleRuler): Don't allocate insanely big pixmaps for double-buffering. Instead, allocate smaller ones and do the recalculation in a smart fashion. Fixes #552777