ifo_types: avoid forcing a higher length in bitfield structures
LLVM ends up using the size of an unsigned int if it's used in the bitfield. In other places the bitfields are using unsigned char which always uses the proper size in the packed structures.
- multichannel_ext_t would end up having a size of 27 instead of 24
- cell_playback_t would end up having a size of 26 instead of 24
- pgci_srp_t would end up having a size of 11 instead of 8
- playback_type_t would end up having a size of 4 instead of 1
v2:
- do the same fix in
nav_types.h
v3:
-
btni_t
is not read as a packed structure and cannot useunsigned char
with 10 bits fields http://dvd.sourceforge.net/dvdinfo/pci_pkt.html#btn_it - This is the reason dvdnav doesn't work with mismatching MS bitfield packing
Merge request reports
Activity
mentioned in commit robUx4/vlc@871fd561
mentioned in merge request vlc!2402 (merged)
mentioned in merge request libdvdnav!51 (closed)
- Resolved by Jean-Baptiste Kempf
This probably requires a bump of the .so version. Although the API is strictly the same, the ABI is different as the structures have different sizes. An update to this libdvdread will break other apps/libraries if they are not recompiled with the new headers.
So, following the
LTVERSION
doc in the configure file:-
DVDREAD_LT_REVISION
= 0 -
DVDREAD_LT_CURRENT
+= 1 -
AGE
+= 1, as it's equivalent to adding an API, it doesn't break previous code compilation.
-
Thanks for this, we've been using this patch for a long time in windows/uwp: https://github.com/xbmc/libdvdread/commit/3e15b0f6d85e810779191961cc9372322600774e#diff-37d1759ff6afc170c414f507e7f951e333b483bcba3598f70ea050a17b69ef05L132
mentioned in commit robUx4/vlc@a1e6e4da
added 1 commit
- 79733599 - nav_types: avoid forcing a higher length in bitfield structures
added 1 commit
- 27b5f2f7 - nav_types: avoid forcing a higher length in bitfield structures
added 8 commits
-
27b5f2f7...23392df9 - 6 commits from branch
videolan:master
- ea158e81 - ifo_types: avoid forcing a higher length in bitfield structures
- f3c27767 - nav_types: avoid forcing a higher length in bitfield structures
-
27b5f2f7...23392df9 - 6 commits from branch
mentioned in merge request !43
mentioned in merge request vlc!2400 (merged)
mentioned in commit robUx4/vlc@f5b18999
mentioned in merge request vlc!2417 (merged)