[libdvbpsi-devel] BAT table: fix compiler warning.
Jean-Paul Saman
git at videolan.org
Wed May 30 16:17:53 CEST 2012
libdvbpsi | branch: master | Jean-Paul Saman <jean-paul.saman at m2x.nl> | Wed May 9 17:04:13 2012 +0200| [7e6453a414ed2bbb5129b3ddaa10f26792329ca0] | committer: Jean-Paul Saman
BAT table: fix compiler warning.
The compiler warned about comparison of signed and unsigned values. This
patch fixes this comparison.
> http://git.videolan.org/gitweb.cgi/libdvbpsi.git/?a=commit;h=7e6453a414ed2bbb5129b3ddaa10f26792329ca0
---
src/tables/bat.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/tables/bat.c b/src/tables/bat.c
index c1ab774..5deed76 100644
--- a/src/tables/bat.c
+++ b/src/tables/bat.c
@@ -469,9 +469,10 @@ void dvbpsi_GatherBATSections(dvbpsi_t *p_dvbpsi,
p_bat_decoder->current_bat = *p_bat_decoder->p_building_bat;
p_bat_decoder->b_current_valid = true;
/* Chain the sections */
+ assert(p_bat_decoder->i_last_section_number > 256);
if (p_bat_decoder->i_last_section_number)
{
- for (int j = 0; j <= p_bat_decoder->i_last_section_number - 1; j++)
+ for (uint8_t j = 0; j <= p_bat_decoder->i_last_section_number - 1; j++)
p_bat_decoder->ap_sections[j]->p_next =
p_bat_decoder->ap_sections[j + 1];
}
More information about the libdvbpsi-devel
mailing list