relpace glib with GObject, to prevent (Segmentation fault)