Commit 628f81b3 authored by Gildas Bazin's avatar Gildas Bazin

* include/vlc_common.h, include/modules_inner.h, modules/codec/ffmpeg/: MSVC...

* include/vlc_common.h, include/modules_inner.h, modules/codec/ffmpeg/: MSVC build fixes by Steve Lhomme (steve dot lhomme at free dot fr) + IMPORT_SYMBOL change by me.
parent 1bc2b279
......@@ -78,6 +78,12 @@
# define EXTERN_SYMBOL
#endif
#if defined( USE_DLL )
# define IMPORT_SYMBOL __declspec(dllimport)
#else
# define IMPORT_SYMBOL
#endif
#define MODULE_STRING STRINGIFY( MODULE_NAME )
/*
......
......@@ -526,11 +526,11 @@ static int64_t GCD( int64_t a, int64_t b )
{ \
if( i_oldsize ) \
{ \
(p_ar) = realloc( p_ar, ((i_oldsize) + 1) * sizeof( *(p_ar) ) ); \
(p_ar) = (void**)realloc( p_ar, ((i_oldsize) + 1) * sizeof( *(p_ar) ) ); \
} \
else \
{ \
(p_ar) = malloc( ((i_oldsize) + 1) * sizeof( *(p_ar) ) ); \
(p_ar) = (void**)malloc( ((i_oldsize) + 1) * sizeof( *(p_ar) ) ); \
} \
if( (i_oldsize) - (i_pos) ) \
{ \
......@@ -932,6 +932,7 @@ typedef __int64 off_t;
# define _OFF_T_DEFINED
# else
# define off_t __int64
/* for wx compatibility typedef long off_t; */
# endif
# endif
......@@ -956,13 +957,7 @@ typedef __int64 off_t;
# define vsnprintf _vsnprintf
# endif
# ifndef _T
# ifdef UNICODE
# define _T(q) L##q
# else
# define _T(q) q
# endif
# endif
# include <tchar.h>
#endif
/* lseek (defined in src/extras/libc.c) */
......
......@@ -116,7 +116,7 @@ int E_(InitAudioDec)( decoder_t *p_dec, AVCodecContext *p_context,
malloc( p_dec->fmt_in.i_extra + FF_INPUT_BUFFER_PADDING_SIZE );
memcpy( p_sys->p_context->extradata,
p_dec->fmt_in.p_extra, p_dec->fmt_in.i_extra );
memset( p_sys->p_context->extradata + p_dec->fmt_in.i_extra, 0,
memset( (char*)p_sys->p_context->extradata + p_dec->fmt_in.i_extra, 0,
FF_INPUT_BUFFER_PADDING_SIZE );
}
......
......@@ -156,8 +156,8 @@ static const char *ppsz_enc_options[] = {
/*****************************************************************************
* OpenEncoder: probe the encoder
*****************************************************************************/
extern int16_t ff_mpeg4_default_intra_matrix[];
extern int16_t ff_mpeg4_default_non_intra_matrix[];
extern int16_t IMPORT_SYMBOL ff_mpeg4_default_intra_matrix[];
extern int16_t IMPORT_SYMBOL ff_mpeg4_default_non_intra_matrix[];
int E_(OpenEncoder)( vlc_object_t *p_this )
{
......
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