Fix #1542 - timeshift: stop crash if speed/skip request w/o service

This can happen because XBMC may send requests even though the sub
has not yet started and the relevant links been made.
This commit is contained in:
Adam Sutton 2013-01-20 12:41:58 +00:00
parent 1d6356a87b
commit a9584156a3

View file

@ -643,6 +643,8 @@ subscription_set_speed ( th_subscription_t *s, int speed )
streaming_message_t *sm;
service_t *t = s->ths_service;
if (!t) return;
pthread_mutex_lock(&t->s_stream_mutex);
sm = streaming_msg_create_code(SMT_SPEED, speed);
@ -661,6 +663,8 @@ subscription_set_skip ( th_subscription_t *s, const streaming_skip_t *skip )
streaming_message_t *sm;
service_t *t = s->ths_service;
if (!t) return;
pthread_mutex_lock(&t->s_stream_mutex);
sm = streaming_msg_create(SMT_SKIP);