git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42957
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
g_object_ref(m_buffer);
GtkTextBuffer* buf_new = gtk_text_buffer_new(NULL);
gtk_text_view_set_buffer(GTK_TEXT_VIEW(m_text), buf_new);
g_object_ref(m_buffer);
GtkTextBuffer* buf_new = gtk_text_buffer_new(NULL);
gtk_text_view_set_buffer(GTK_TEXT_VIEW(m_text), buf_new);
- // gtk_text_view_set_buffer adds its own reference
- g_object_unref(buf_new);
+ // FIXME: this leaks the new buffer, since gtk_text_view_set_buffer
+ // adds its own reference, but unrefing it here can cause a crash later