]> git.tue.mpg.de Git - paraslash.git/commitdiff
mp4: Make most members of struct mp4_track unsigned.
authorAndre Noll <maan@tuebingen.mpg.de>
Wed, 18 Aug 2021 13:02:43 +0000 (15:02 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Mon, 30 May 2022 19:37:35 +0000 (21:37 +0200)
All of these get initialized by reading an unsigned 32 bit value from
the file, so they should also be unsigned.

mp4.c

diff --git a/mp4.c b/mp4.c
index 03f80ba9aa23a473050f6a3eb85f855149901340..61feafdf2ce744aa593b4eaeb4c16d06aa60250a 100644 (file)
--- a/mp4.c
+++ b/mp4.c
 
 struct mp4_track {
        bool is_audio;
-       int32_t channelCount;
+       uint32_t channelCount;
        uint16_t sampleRate;
 
        /* stsz */
-       int32_t stsz_sample_size;
-       int32_t stsz_sample_count;
-       int32_t *stsz_table;
+       uint32_t stsz_sample_size;
+       uint32_t stsz_sample_count;
+       uint32_t *stsz_table;
 
        /* stts */
-       int32_t stts_entry_count;
-       int32_t *stts_sample_count;
-       int32_t *stts_sample_delta;
+       uint32_t stts_entry_count;
+       uint32_t *stts_sample_count;
+       uint32_t *stts_sample_delta;
 
        /* stsc */
-       int32_t stsc_entry_count;
-       int32_t *stsc_first_chunk;
-       int32_t *stsc_samples_per_chunk;
-       int32_t *stsc_sample_desc_index;
+       uint32_t stsc_entry_count;
+       uint32_t *stsc_first_chunk;
+       uint32_t *stsc_samples_per_chunk;
+       uint32_t *stsc_sample_desc_index;
 
        /* stsc */
-       int32_t stco_entry_count;
-       int32_t *stco_chunk_offset;
+       uint32_t stco_entry_count;
+       uint32_t *stco_chunk_offset;
 
        uint32_t timeScale;
        uint64_t duration;