Commit c738c2d5 authored by Erik Van Grunderbeeck's avatar Erik Van Grunderbeeck Committed by hpi1

Add some explicit typecasting to make strict C99 compilers happy.

Signed-off-by: default avatarErik Van Grunderbeeck <erik@arawix.com>
parent ac1f87fb
...@@ -70,7 +70,7 @@ BDJAVA* bdj_open(const char *path, const char* start, void* bd, void* registers) ...@@ -70,7 +70,7 @@ BDJAVA* bdj_open(const char *path, const char* start, void* bd, void* registers)
args.options = option; args.options = option;
args.ignoreUnrecognized = JNI_FALSE; // don't ignore unrecognized options args.ignoreUnrecognized = JNI_FALSE; // don't ignore unrecognized options
fptr_JNI_CreateJavaVM JNI_CreateJavaVM_fp = dl_dlsym(jvm_lib, fptr_JNI_CreateJavaVM JNI_CreateJavaVM_fp = (fptr_JNI_CreateJavaVM)dl_dlsym(jvm_lib,
"JNI_CreateJavaVM"); "JNI_CreateJavaVM");
if (JNI_CreateJavaVM_fp == NULL) { if (JNI_CreateJavaVM_fp == NULL) {
......
...@@ -149,7 +149,7 @@ struct bluray { ...@@ -149,7 +149,7 @@ struct bluray {
#ifdef DLOPEN_CRYPTO_LIBS #ifdef DLOPEN_CRYPTO_LIBS
# define DL_CALL(lib,func,param,...) \ # define DL_CALL(lib,func,param,...) \
do { \ do { \
fptr_p_void fptr = dl_dlsym(lib, #func); \ fptr_p_void fptr = (fptr_p_void)dl_dlsym(lib, #func); \
if (fptr) { \ if (fptr) { \
fptr(param, ##__VA_ARGS__); \ fptr(param, ##__VA_ARGS__); \
} \ } \
...@@ -471,8 +471,8 @@ static int _libaacs_load(BLURAY *bd) ...@@ -471,8 +471,8 @@ static int _libaacs_load(BLURAY *bd)
DEBUG(DBG_BLURAY, "Loading libaacs (%p)\n", bd->h_libaacs); DEBUG(DBG_BLURAY, "Loading libaacs (%p)\n", bd->h_libaacs);
bd->libaacs_open = dl_dlsym(bd->h_libaacs, "aacs_open"); bd->libaacs_open = (fptr_p_void)dl_dlsym(bd->h_libaacs, "aacs_open");
bd->libaacs_decrypt_unit = dl_dlsym(bd->h_libaacs, "aacs_decrypt_unit"); bd->libaacs_decrypt_unit = (fptr_int)dl_dlsym(bd->h_libaacs, "aacs_decrypt_unit");
if (bd->libaacs_open && bd->libaacs_decrypt_unit) { if (bd->libaacs_open && bd->libaacs_decrypt_unit) {
DEBUG(DBG_BLURAY, "Loaded libaacs (%p)\n", bd->h_libaacs); DEBUG(DBG_BLURAY, "Loaded libaacs (%p)\n", bd->h_libaacs);
...@@ -535,7 +535,7 @@ static uint8_t *_libaacs_get_vid(BLURAY *bd) ...@@ -535,7 +535,7 @@ static uint8_t *_libaacs_get_vid(BLURAY *bd)
{ {
if (bd->aacs) { if (bd->aacs) {
#ifdef DLOPEN_CRYPTO_LIBS #ifdef DLOPEN_CRYPTO_LIBS
fptr_p_void fptr = dl_dlsym(bd->h_libaacs, "aacs_get_vid"); fptr_p_void fptr = (fptr_p_void)dl_dlsym(bd->h_libaacs, "aacs_get_vid");
if (fptr) { if (fptr) {
return (uint8_t*)fptr(bd->aacs); return (uint8_t*)fptr(bd->aacs);
} }
...@@ -610,9 +610,9 @@ static int _libbdplus_load(BLURAY *bd) ...@@ -610,9 +610,9 @@ static int _libbdplus_load(BLURAY *bd)
DEBUG(DBG_BLURAY, "Loading libbdplus (%p)\n", bd->h_libbdplus); DEBUG(DBG_BLURAY, "Loading libbdplus (%p)\n", bd->h_libbdplus);
bd->bdplus_init = dl_dlsym(bd->h_libbdplus, "bdplus_init"); bd->bdplus_init = (fptr_p_void)dl_dlsym(bd->h_libbdplus, "bdplus_init");
bd->bdplus_seek = dl_dlsym(bd->h_libbdplus, "bdplus_seek"); bd->bdplus_seek = (fptr_int32)dl_dlsym(bd->h_libbdplus, "bdplus_seek");
bd->bdplus_fixup = dl_dlsym(bd->h_libbdplus, "bdplus_fixup"); bd->bdplus_fixup = (fptr_int32)dl_dlsym(bd->h_libbdplus, "bdplus_fixup");
if (bd->bdplus_init && bd->bdplus_seek && bd->bdplus_fixup) { if (bd->bdplus_init && bd->bdplus_seek && bd->bdplus_fixup) {
DEBUG(DBG_BLURAY, "Loaded libbdplus (%p)\n", bd->h_libbdplus); DEBUG(DBG_BLURAY, "Loaded libbdplus (%p)\n", bd->h_libbdplus);
......
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