iso639: de-duplicate code lookup handling
...with a new function, which also replaces direct use of the three code-specific functions. all users of these three functions had a common pattern of using the iso-639-1 lookup for len==2 codes, and for len==3 doing a 2B lookup, falling back to a 2T lookup if that failed. this pattern is now implemented in the new `vlc_find_iso639()` function. the three individual functions are now made private, not being needed publicly anymore. they also now just do a straight `strcmp()` rather than `strncmp()` because they are only called for the right length of strings. the implementation will be tweaked slightly in the next commit.
parent
570a218d
No related branches found
No related tags found
Showing
- include/vlc_iso_lang.h 15 additions, 4 deletionsinclude/vlc_iso_lang.h
- modules/mux/mp4/libmp4mux.c 1 addition, 9 deletionsmodules/mux/mp4/libmp4mux.c
- modules/mux/mpeg/ps.c 1 addition, 13 deletionsmodules/mux/mpeg/ps.c
- modules/mux/mpeg/ts.c 1 addition, 11 deletionsmodules/mux/mpeg/ts.c
- src/input/es_out.c 4 additions, 12 deletionssrc/input/es_out.c
- src/libvlccore.sym 1 addition, 3 deletionssrc/libvlccore.sym
- src/text/iso_lang.c 21 additions, 6 deletionssrc/text/iso_lang.c
Loading
Please register or sign in to comment