Commit 61a0d7c4 authored by Jean-Paul Saman's avatar Jean-Paul Saman

Move common dvbpsi_*_decoder_t members to dvbpsi_decoder_t

The struct members ::p_current_valid, ::i_last_section_number and
::ap_sections[] array are used by all PSI section decoders. They are
moved to DVBPSI_DECODER_COMMON.
parent 2807e23e
......@@ -185,6 +185,12 @@ dvbpsi_decoder_t *dvbpsi_NewDecoder(dvbpsi_callback_gather_t pf_gather,
p_decoder->b_discontinuity = b_discontinuity;
p_decoder->i_continuity_counter = DVBPSI_INVALID_CC;
p_decoder->p_current_section = NULL;
p_decoder->b_current_valid = false;
p_decoder->i_last_section_number = 0;
for (unsigned int i = 0; i <= 255; i++)
p_decoder->ap_sections[i] = NULL;
p_decoder->b_complete_header = false;
return p_decoder;
......@@ -197,6 +203,13 @@ void dvbpsi_DeleteDecoder(dvbpsi_decoder_t *p_decoder)
{
assert(p_decoder);
for (unsigned int i = 0; i <= 255; i++)
{
if (p_decoder->ap_sections[i])
dvbpsi_DeletePSISections(p_decoder->ap_sections[i]);
p_decoder->ap_sections[i] = NULL;
}
dvbpsi_DeletePSISections(p_decoder->p_current_section);
free(p_decoder);
}
......
......@@ -200,6 +200,9 @@ typedef void (* dvbpsi_callback_gather_t)(dvbpsi_t *p_dvbpsi, /*!< pointer to d
uint8_t i_continuity_counter; /*!< Continuity counter */ \
bool b_discontinuity; /*!< Discontinuity flag */ \
dvbpsi_psi_section_t *p_current_section; /*!< Current section */ \
bool b_current_valid; /*!< Current valid indicator */ \
uint8_t i_last_section_number;/*!< Last received section number */ \
dvbpsi_psi_section_t *ap_sections[256]; /*!< Array of received PSI sections */ \
int i_need; /*!< Bytes needed */ \
bool b_complete_header; /*!< Flag for header completion */
......
......@@ -53,11 +53,6 @@ typedef struct dvbpsi_atsc_eit_decoder_s
dvbpsi_atsc_eit_t current_eit;
dvbpsi_atsc_eit_t * p_building_eit;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_atsc_eit_decoder_t;
......@@ -121,11 +116,7 @@ bool dvbpsi_atsc_AttachEIT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
/* EIT decoder information */
p_eit_decoder->pf_eit_callback = pf_callback;
p_eit_decoder->p_cb_data = p_cb_data;
/* EIT decoder initial state */
p_eit_decoder->b_current_valid = false;
p_eit_decoder->p_building_eit = NULL;
for (int i = 0; i < 256; i++)
p_eit_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -161,15 +152,6 @@ void dvbpsi_atsc_DetachEIT(dvbpsi_t * p_dvbpsi, uint8_t i_table_id, uint16_t i_e
dvbpsi_atsc_DeleteEIT(p_eit_decoder->p_building_eit);
p_eit_decoder->p_building_eit = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_eit_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_eit_decoder->ap_sections[i]);
p_eit_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -59,11 +59,6 @@ typedef struct dvbpsi_atsc_ett_decoder_s
dvbpsi_atsc_ett_t current_ett;
dvbpsi_atsc_ett_t * p_building_ett;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections[256];
} dvbpsi_atsc_ett_decoder_t;
/*****************************************************************************
......@@ -125,12 +120,7 @@ bool dvbpsi_atsc_AttachETT(dvbpsi_t * p_dvbpsi, uint8_t i_table_id, uint16_t i_e
/* ETT decoder information */
p_ett_decoder->pf_ett_callback = pf_callback;
p_ett_decoder->p_cb_data = p_cb_data;
/* ETT decoder initial state */
p_ett_decoder->b_current_valid = false;
p_ett_decoder->p_building_ett = NULL;
for (unsigned int i = 0; i < 256; i++)
p_ett_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -167,15 +157,6 @@ void dvbpsi_atsc_DetachETT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
dvbpsi_atsc_DeleteETT(p_ett_decoder->p_building_ett);
p_ett_decoder->p_building_ett = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_ett_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_ett_decoder->ap_sections[i]);
p_ett_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -54,11 +54,6 @@ typedef struct dvbpsi_atsc_mgt_decoder_s
dvbpsi_atsc_mgt_t current_mgt;
dvbpsi_atsc_mgt_t * p_building_mgt;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_atsc_mgt_decoder_t;
static dvbpsi_descriptor_t *dvbpsi_atsc_MGTAddDescriptor(
......@@ -125,11 +120,7 @@ bool dvbpsi_atsc_AttachMGT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
/* MGT decoder information */
p_mgt_decoder->pf_mgt_callback = pf_callback;
p_mgt_decoder->p_cb_data = p_cb_data;
/* MGT decoder initial state */
p_mgt_decoder->b_current_valid = false;
p_mgt_decoder->p_building_mgt = NULL;
for (unsigned int i = 0; i < 256; i++)
p_mgt_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -166,15 +157,6 @@ void dvbpsi_atsc_DetachMGT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
dvbpsi_atsc_DeleteMGT(p_mgt_decoder->p_building_mgt);
p_mgt_decoder->p_building_mgt = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_mgt_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_mgt_decoder->ap_sections[i]);
p_mgt_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -53,11 +53,6 @@ typedef struct dvbpsi_atsc_stt_decoder_s
dvbpsi_atsc_stt_t current_stt;
dvbpsi_atsc_stt_t * p_building_stt;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_atsc_stt_decoder_t;
dvbpsi_descriptor_t *dvbpsi_atsc_STTAddDescriptor(dvbpsi_atsc_stt_t *p_stt,
......@@ -111,14 +106,8 @@ bool dvbpsi_atsc_AttachSTT(dvbpsi_t* p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
/* STT decoder information */
p_stt_decoder->pf_stt_callback = pf_stt_callback;
p_stt_decoder->p_cb_data = p_cb_data;
/* VCT decoder initial state */
p_stt_decoder->b_current_valid = false;
p_stt_decoder->p_building_stt = NULL;
for(unsigned int i = 0; i < 256; i++)
p_stt_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -155,15 +144,6 @@ void dvbpsi_atsc_DetachSTT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
dvbpsi_atsc_DeleteSTT(p_stt_decoder->p_building_stt);
p_stt_decoder->p_building_stt = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_stt_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_stt_decoder->ap_sections[i]);
p_stt_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -52,11 +52,6 @@ typedef struct dvbpsi_atsc_vct_decoder_s
dvbpsi_atsc_vct_t current_vct;
dvbpsi_atsc_vct_t * p_building_vct;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_atsc_vct_decoder_t;
static dvbpsi_descriptor_t *dvbpsi_atsc_VCTAddDescriptor(
......@@ -135,13 +130,8 @@ bool dvbpsi_atsc_AttachVCT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
/* VCT decoder information */
p_vct_decoder->pf_vct_callback = pf_vct_callback;
p_vct_decoder->p_cb_data = p_cb_data;
/* VCT decoder initial state */
p_vct_decoder->b_current_valid = false;
p_vct_decoder->p_building_vct = NULL;
for(unsigned int i = 0; i < 256; i++)
p_vct_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -176,15 +166,6 @@ void dvbpsi_atsc_DetachVCT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_ex
dvbpsi_atsc_DeleteVCT(p_vct_decoder->p_building_vct);
p_vct_decoder->p_building_vct = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_vct_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_vct_decoder->ap_sections[i]);
p_vct_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -92,13 +92,8 @@ bool dvbpsi_AttachBAT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id,
/* BAT decoder information */
p_bat_decoder->pf_bat_callback = pf_callback;
p_bat_decoder->p_cb_data = p_cb_data;
/* BAT decoder initial state */
p_bat_decoder->b_current_valid = false;
p_bat_decoder->p_building_bat = NULL;
for (unsigned int i = 0; i < 256; i++)
p_bat_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -131,15 +126,6 @@ void dvbpsi_DetachBAT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
dvbpsi_DeleteBAT(p_bat_decoder->p_building_bat);
p_bat_decoder->p_building_bat = NULL;
for (unsigned int i = 0; i < 256; i++)
{
if (p_bat_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_bat_decoder->ap_sections[i]);
p_bat_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -44,11 +44,6 @@ typedef struct dvbpsi_bat_decoder_s
dvbpsi_bat_t current_bat;
dvbpsi_bat_t * p_building_bat;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_bat_decoder_t;
/*****************************************************************************
......
......@@ -69,11 +69,7 @@ bool dvbpsi_AttachCAT(dvbpsi_t *p_dvbpsi, dvbpsi_cat_callback pf_callback,
/* CAT decoder configuration */
p_cat_decoder->pf_cat_callback = pf_callback;
p_cat_decoder->p_cb_data = p_cb_data;
/* CAT decoder initial state */
p_cat_decoder->b_current_valid = false;
p_cat_decoder->p_building_cat = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_cat_decoder->ap_sections[i] = NULL;
p_dvbpsi->p_private = p_cat_decoder;
return true;
......@@ -95,15 +91,6 @@ void dvbpsi_DetachCAT(dvbpsi_t *p_dvbpsi)
dvbpsi_DeleteCAT(p_cat_decoder->p_building_cat);
p_cat_decoder->p_building_cat = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_cat_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_cat_decoder->ap_sections[i]);
p_cat_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DeleteDecoder(p_dvbpsi->p_private);
p_dvbpsi->p_private = NULL;
}
......
......@@ -45,11 +45,6 @@ typedef struct dvbpsi_cat_decoder_s
dvbpsi_cat_t current_cat;
dvbpsi_cat_t * p_building_cat;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_cat_decoder_t;
/*****************************************************************************
......
......@@ -92,11 +92,7 @@ bool dvbpsi_AttachEIT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
/* EIT decoder information */
p_eit_decoder->pf_eit_callback = pf_callback;
p_eit_decoder->p_cb_data = p_cb_data;
/* EIT decoder initial state */
p_eit_decoder->b_current_valid = false;
p_eit_decoder->p_building_eit = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_eit_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -131,15 +127,6 @@ void dvbpsi_DetachEIT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id,
dvbpsi_DeleteEIT(p_eit_decoder->p_building_eit);
p_eit_decoder->p_building_eit = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_eit_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_eit_decoder->ap_sections[i]);
p_eit_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -43,11 +43,7 @@ typedef struct dvbpsi_eit_decoder_s
dvbpsi_eit_t current_eit;
dvbpsi_eit_t * p_building_eit;
bool b_current_valid;
uint8_t i_last_section_number;
uint8_t i_first_received_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_eit_decoder_t;
......
......@@ -95,11 +95,7 @@ bool dvbpsi_AttachNIT(dvbpsi_t* p_dvbpsi, uint8_t i_table_id,
p_nit_decoder->i_network_id = i_extension;
p_nit_decoder->pf_nit_callback = pf_callback;
p_nit_decoder->p_cb_data = p_cb_data;
/* NIT decoder initial state */
p_nit_decoder->b_current_valid = false;
p_nit_decoder->p_building_nit = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_nit_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -131,15 +127,6 @@ void dvbpsi_DetachNIT(dvbpsi_t * p_dvbpsi, uint8_t i_table_id,
dvbpsi_DeleteNIT(p_nit_decoder->p_building_nit);
p_nit_decoder->p_building_nit = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_nit_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_nit_decoder->ap_sections[i]);
p_nit_decoder->ap_sections[i] = NULL;
}
}
/* Free demux sub table decoder */
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
......
......@@ -47,11 +47,6 @@ typedef struct dvbpsi_nit_decoder_s
dvbpsi_nit_t current_nit;
dvbpsi_nit_t * p_building_nit;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_nit_decoder_t;
/*****************************************************************************
......
......@@ -66,14 +66,8 @@ bool dvbpsi_AttachPAT(dvbpsi_t *p_dvbpsi, dvbpsi_pat_callback pf_callback,
/* PAT decoder information */
p_pat_decoder->pf_pat_callback = pf_callback;
p_pat_decoder->p_cb_data = p_cb_data;
/* PAT decoder initial state */
p_pat_decoder->b_current_valid = false;
p_pat_decoder->p_building_pat = NULL;
for(unsigned int i = 0; i <= 255; i++)
p_pat_decoder->ap_sections[i] = NULL;
p_dvbpsi->p_private = (void *)p_pat_decoder;
return true;
}
......@@ -93,13 +87,6 @@ void dvbpsi_DetachPAT(dvbpsi_t *p_dvbpsi)
dvbpsi_DeletePAT(p_pat_decoder->p_building_pat);
p_pat_decoder->p_building_pat = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_pat_decoder->ap_sections[i])
dvbpsi_DeletePSISections(p_pat_decoder->ap_sections[i]);
p_pat_decoder->ap_sections[i] = NULL;
}
dvbpsi_DeleteDecoder(p_dvbpsi->p_private);
p_dvbpsi->p_private = NULL;
}
......
......@@ -43,11 +43,6 @@ typedef struct dvbpsi_pat_decoder_s
dvbpsi_pat_t current_pat;
dvbpsi_pat_t * p_building_pat;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_pat_decoder_t;
......
......@@ -70,12 +70,7 @@ bool dvbpsi_AttachPMT(dvbpsi_t *p_dvbpsi, uint16_t i_program_number,
p_pmt_decoder->i_program_number = i_program_number;
p_pmt_decoder->pf_pmt_callback = pf_callback;
p_pmt_decoder->p_cb_data = p_cb_data;
/* PMT decoder initial state */
p_pmt_decoder->b_current_valid = false;
p_pmt_decoder->p_building_pmt = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_pmt_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -96,13 +91,6 @@ void dvbpsi_DetachPMT(dvbpsi_t *p_dvbpsi)
dvbpsi_DeletePMT(p_pmt_decoder->p_building_pmt);
p_pmt_decoder->p_building_pmt = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_pmt_decoder->ap_sections[i])
dvbpsi_DeletePSISections(p_pmt_decoder->ap_sections[i]);
p_pmt_decoder->ap_sections[i] = NULL;
}
dvbpsi_DeleteDecoder((dvbpsi_decoder_t *)p_dvbpsi->p_private);
p_dvbpsi->p_private = NULL;
}
......
......@@ -45,11 +45,6 @@ typedef struct dvbpsi_pmt_decoder_s
dvbpsi_pmt_t current_pmt;
dvbpsi_pmt_t * p_building_pmt;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_pmt_decoder_t;
/*****************************************************************************
......
......@@ -91,12 +91,7 @@ bool dvbpsi_AttachSDT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
/* SDT decoder information */
p_sdt_decoder->pf_sdt_callback = pf_callback;
p_sdt_decoder->p_cb_data = p_cb_data;
/* SDT decoder initial state */
p_sdt_decoder->b_current_valid = false;
p_sdt_decoder->p_building_sdt = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_sdt_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -132,15 +127,6 @@ void dvbpsi_DetachSDT(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
dvbpsi_DeleteSDT(p_sdt_decoder->p_building_sdt);
p_sdt_decoder->p_building_sdt = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_sdt_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_sdt_decoder->ap_sections[i]);
p_sdt_decoder->ap_sections[i] = NULL;
}
}
/* Free sub table decoder */
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
......
......@@ -43,11 +43,6 @@ typedef struct dvbpsi_sdt_decoder_s
dvbpsi_sdt_t current_sdt;
dvbpsi_sdt_t * p_building_sdt;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_sdt_decoder_t;
/*****************************************************************************
......
......@@ -93,12 +93,8 @@ bool dvbpsi_AttachSIS(dvbpsi_t *p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
/* SIS decoder information */
p_sis_decoder->pf_sis_callback = pf_callback;
p_sis_decoder->p_cb_data = p_cb_data;
/* SIS decoder initial state */
p_sis_decoder->b_current_valid = false;
p_sis_decoder->p_building_sis = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_sis_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -135,15 +131,6 @@ void dvbpsi_DetachSIS(dvbpsi_t *p_dvbpsi, uint8_t i_table_id,
dvbpsi_DeleteSIS(p_sis_decoder->p_building_sis);
p_sis_decoder->p_building_sis = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_sis_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_sis_decoder->ap_sections[i]);
p_sis_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -43,10 +43,6 @@ typedef struct dvbpsi_sis_decoder_s
dvbpsi_sis_t current_sis;
dvbpsi_sis_t *p_building_sis;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_sis_decoder_t;
/*****************************************************************************
......
......@@ -95,12 +95,7 @@ bool dvbpsi_AttachTOT(dvbpsi_t* p_dvbpsi, uint8_t i_table_id, uint16_t i_extensi
/* TDT/TOT decoder information */
p_tot_decoder->pf_tot_callback = pf_callback;
p_tot_decoder->p_cb_data = p_cb_data;
/* TDT/TOT decoder initial state */
p_tot_decoder->b_current_valid = false;
p_tot_decoder->p_building_tot = NULL;
for (unsigned int i = 0; i <= 255; i++)
p_tot_decoder->ap_sections[i] = NULL;
return true;
}
......@@ -138,15 +133,6 @@ void dvbpsi_DetachTOT(dvbpsi_t* p_dvbpsi, uint8_t i_table_id,
dvbpsi_DeleteTOT(p_tot_decoder->p_building_tot);
p_tot_decoder->p_building_tot = NULL;
for (unsigned int i = 0; i <= 255; i++)
{
if (p_tot_decoder->ap_sections[i])
{
dvbpsi_DeletePSISections(p_tot_decoder->ap_sections[i]);
p_tot_decoder->ap_sections[i] = NULL;
}
}
dvbpsi_DetachDemuxSubDecoder(p_demux, p_subdec);
dvbpsi_DeleteDemuxSubDecoder(p_subdec);
}
......
......@@ -46,9 +46,6 @@ typedef struct dvbpsi_tot_decoder_s
dvbpsi_tot_t current_tot;
dvbpsi_tot_t *p_building_tot;
bool b_current_valid;
uint8_t i_last_section_number;
dvbpsi_psi_section_t * ap_sections [256];
} dvbpsi_tot_decoder_t;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment