use a volatile var instead of pthread_kill for checking if gstreamer thread alive