X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/937013e0fd914d4c42f9f5ec98da665986b93dfa..89b4415803685b243946e4941522be8232621fa6:/src/gtk/scrolbar.cpp

diff --git a/src/gtk/scrolbar.cpp b/src/gtk/scrolbar.cpp
index 413e8fbe3c..0a76b68267 100644
--- a/src/gtk/scrolbar.cpp
+++ b/src/gtk/scrolbar.cpp
@@ -144,6 +144,7 @@ bool wxScrollBar::Create(wxWindow *parent, wxWindowID id,
         m_widget = gtk_vscrollbar_new( (GtkAdjustment *) NULL );
     else
         m_widget = gtk_hscrollbar_new( (GtkAdjustment *) NULL );
+    g_object_ref(m_widget);
 
     m_scrollBar[0] = (GtkRange*)m_widget;