Although this bug is already reported on the BerliOs-ProjectPage, I decided to start a new thread because I've found a way to reproduce this crash and to show that this bug is still existant in current svn-versions.
The problem: CodeBlocks crashes quite often when doing copy & paste. I don't know if it depends on the text which should be pasted, but this is the way I can reproduce the crash:
1. start C::B and open or create an empty cpp-file.
2. paste the following code "as it is" into the empty cpp-file
#include <gtkmm.h>
#include <gtkmm/button.h>
#include <gtkmm/image.h>
#include <libglademm-2.4/libglademm/xml.h>
#include <iostream>
3. mark the complete code in the cpp-file.
4. press copy and then paste and C::B should crash.
The crash happens very often and not only when pasting this special piece of code, but this special case was the only one I found to reproduce it.
I'm using Arch-Linux 0.7.2:
uname -a
2.6.18-ARCH #1 SMP PREEMPT Thu Nov 30 21:32:54 CET 2006 i686 AMD Athlon(tm) 64 Processor 3200+ AuthenticAMD GNU/Linux
The bug occured with
svn build rev 3353 (2006-12-07 14:49:33) gcc 4.1.2 Linux/unicode
as well as with a version from the 3rd of december (don't remember the version-number).
Here's the backtrace:
codeblocks -d
*** glibc detected *** codeblocks: double free or corruption (!prev): 0x08c5a0d8 ***
======= Backtrace: =========
/lib/libc.so.6[0xb72fdb10]
/lib/libc.so.6(__libc_free+0x89)[0xb72ff1a9]
/usr/lib/libwx_gtk2u_core-2.6.so.0[0xb773fe3c]
/usr/lib/libgtk-x11-2.0.so.0[0xb6ff89c6]
/usr/lib/libgobject-2.0.so.0(g_closure_invoke+0x13b)[0xb6e3007b]
/usr/lib/libgobject-2.0.so.0[0xb6e404e9]
/usr/lib/libgobject-2.0.so.0(g_signal_emit_valist+0x899)[0xb6e419a9]
/usr/lib/libgobject-2.0.so.0(g_signal_emit_by_name+0xee)[0xb6e4475e]
/usr/lib/libgtk-x11-2.0.so.0[0xb70556e4]
/usr/lib/libgtk-x11-2.0.so.0(gtk_selection_convert+0x145)[0xb7056565]
/usr/lib/libwx_gtk2u_core-2.6.so.0(_ZN11wxClipboard7GetDataER12wxDataObject+0x1ec)[0xb774009c]
/usr/local/lib/libcodeblocks.so.0(_ZN11ScintillaWX5PasteEv+0x17f)[0xb7d9a04f]
/usr/local/lib/libcodeblocks.so.0(_ZN6Editor7WndProcEjml+0x1c5a)[0xb7dc77ba]
/usr/local/lib/libcodeblocks.so.0(_ZN13ScintillaBase7WndProcEjml+0x2b7)[0xb7e4c437]
/usr/local/lib/libcodeblocks.so.0(_ZN11ScintillaWX7WndProcEjml+0x44)[0xb7d985c4]
/usr/local/lib/libcodeblocks.so.0(_ZN11wxScintilla7SendMsgEill+0x2f)[0xb7d9ca0f]
/usr/local/lib/libcodeblocks.so.0(_ZN11wxScintilla5PasteEv+0x32)[0xb7d9f062]
/usr/local/lib/libcodeblocks.so.0(_ZN8cbEditor5PasteEv+0x25)[0xb7bd6d95]
codeblocks(_ZN9MainFrame11OnEditPasteER14wxCommandEvent+0x38)[0x807aff8]
/usr/lib/libwx_baseu-2.6.so.0(_ZNK12wxAppConsole11HandleEventEP12wxEvtHandlerMS0_FvR7wxEventES3_+0x35)[0xb7533395]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler21ProcessEventIfMatchesERK21wxEventTableEntryBasePS_R7wxEvent+0x92)[0xb75bf662]
/usr/lib/libwx_baseu-2.6.so.0(_ZN16wxEventHashTable11HandleEventER7wxEventP12wxEvtHandler+0x7b)[0xb75bf7ab]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0xcf)[0xb75bf91f]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_baseu-2.6.so.0(_ZN12wxEvtHandler12ProcessEventER7wxEvent+0x6e)[0xb75bf8be]
/usr/lib/libwx_gtk2u_core-2.6.so.0[0xb77c0568]
/usr/lib/libgobject-2.0.so.0(g_cclosure_marshal_VOID__VOID+0x4b)[0xb6e3d41b]
/usr/lib/libgobject-2.0.so.0(g_closure_invoke+0x13b)[0xb6e3007b]
/usr/lib/libgobject-2.0.so.0[0xb6e404e9]
/usr/lib/libgobject-2.0.so.0(g_signal_emit_valist+0x899)[0xb6e419a9]
/usr/lib/libgobject-2.0.so.0(g_signal_emit+0x29)[0xb6e41b59]
/usr/lib/libgtk-x11-2.0.so.0[0xb711002d]
/usr/lib/libgobject-2.0.so.0(g_closure_invoke+0x13b)[0xb6e3007b]
/usr/lib/libgobject-2.0.so.0[0xb6e404e9]
/usr/lib/libgobject-2.0.so.0(g_signal_emit_valist+0x678)[0xb6e41788]
======= Memory map: ========
08048000-080df000 r-xp 00000000 03:02 121214 /usr/local/bin/codeblocks
080df000-080e5000 rwxp 00096000 03:02 121214 /usr/local/bin/codeblocks
080e5000-08cd4000 rwxp 080e5000 00:00 0 [heap]
b285b000-b285c000 ---p b285b000 00:00 0
b285c000-b305c000 rwxp b285c000 00:00 0
b305c000-b3068000 r-xp 00000000 03:02 121681 /usr/share/fonts/TTF/VeraMoBd.ttf
b3068000-b3069000 ---p b3068000 00:00 0
b3069000-b3869000 rwxp b3069000 00:00 0
b3869000-b3876000 r-xp 00000000 03:02 121680 /usr/share/fonts/TTF/VeraMono.ttf
b3876000-b388c000 r-xp 00000000 03:02 121460 /usr/local/share/codeblocks/plugins/libcb_koders.so
b388c000-b388d000 rwxp 00016000 03:02 121460 /usr/local/share/codeblocks/plugins/libcb_koders.so
b388d000-b388e000 ---p b388d000 00:00 0
b388e000-b408e000 rwxp b388e000 00:00 0
b408e000-b4130000 r-xp 00000000 03:02 121260 /usr/local/share/codeblocks/plugins/libcodecompletion.so
b4130000-b4135000 rwxp 000a1000 03:02 121260 /usr/local/share/codeblocks/plugins/libcodecompletion.so
b4135000-b413d000 rwxp b4135000 00:00 0
b413d000-b4150000 r-xp 00000000 03:02 121491 /usr/local/share/codeblocks/plugins/libhelp_plugin.so
b4150000-b4151000 rwxp 00013000 03:02 121491 /usr/local/share/codeblocks/plugins/libhelp_plugin.so
b4151000-b4161000 r-xp 00000000 03:02 121231 /usr/local/share/codeblocks/plugins/libclasswizard.so
b4161000-b4162000 rwxp 00010000 03:02 121231 /usr/local/share/codeblocks/plugins/libclasswizard.so
b4162000-b4170000 r-xp 00000000 03:02 121485 /usr/local/shaAbgebrochen