diff options
author | Oleg Oshmyan <chortos@inbox.lv> | 2021-05-01 02:14:50 +0300 |
---|---|---|
committer | Oleg Oshmyan <chortos@inbox.lv> | 2021-05-01 02:18:01 +0300 |
commit | d82f9994d1a8ee10e1e65332aada0789084f4d89 (patch) | |
tree | c044369255ce042f2ecd1d4371807487fd218df3 | |
parent | db5813281393e39ea996118fd02ddb9442ad3889 (diff) | |
download | libass-d82f9994d1a8ee10e1e65332aada0789084f4d89.tar.bz2 libass-d82f9994d1a8ee10e1e65332aada0789084f4d89.tar.xz |
directwrite: cast function pointer through void* to quelch warning
GCC and MSVC (at least) warn about this cast as the function types
appear to be incompatible. This is correct with GetProcAddress.
-rw-r--r-- | libass/ass_directwrite.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libass/ass_directwrite.c b/libass/ass_directwrite.c index 0ad9118..b5cc299 100644 --- a/libass/ass_directwrite.c +++ b/libass/ass_directwrite.c @@ -763,8 +763,9 @@ ASS_FontProvider *ass_directwrite_add_provider(ASS_Library *lib, if (!directwrite_lib) goto cleanup; - DWriteCreateFactoryPtr = (DWriteCreateFactoryFn)GetProcAddress(directwrite_lib, - "DWriteCreateFactory"); + DWriteCreateFactoryPtr = + (DWriteCreateFactoryFn)(void *)GetProcAddress(directwrite_lib, + "DWriteCreateFactory"); if (!DWriteCreateFactoryPtr) goto cleanup; |