Added G_DEBUG and G_SLICE env variable to make pointer errors more visible.