From 0b088cb4dd979f63adac39e4894dbf19b8d9129e Mon Sep 17 00:00:00 2001 From: Adam Sutton Date: Sun, 16 Jun 2013 11:04:12 +0100 Subject: [PATCH] mpegts: ensure fe type is set before normal config load If we don't do this some checks (such as network type on set) will fail as the fe type may not be set before setting the network. --- src/input/mpegts/linuxdvb/linuxdvb_frontend.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/input/mpegts/linuxdvb/linuxdvb_frontend.c b/src/input/mpegts/linuxdvb/linuxdvb_frontend.c index 842d1d25..c4abb6af 100644 --- a/src/input/mpegts/linuxdvb/linuxdvb_frontend.c +++ b/src/input/mpegts/linuxdvb/linuxdvb_frontend.c @@ -845,11 +845,9 @@ linuxdvb_frontend_create0 return NULL; } - linuxdvb_frontend_t *lfe - = (linuxdvb_frontend_t*) - mpegts_input_create0(calloc(1, sizeof(linuxdvb_frontend_t)), - idc, uuid, conf); + linuxdvb_frontend_t *lfe = calloc(1, sizeof(linuxdvb_frontend_t)); lfe->lfe_info.type = type; + lfe = (linuxdvb_frontend_t*)mpegts_input_create0((mpegts_input_t*)lfe, idc, uuid, conf); /* Input callbacks */ lfe->mi_is_enabled = linuxdvb_frontend_is_enabled;