diff options
author | Måns Rullgård <mans@mansr.com> | 2007-07-08 15:56:31 +0000 |
---|---|---|
committer | Måns Rullgård <mans@mansr.com> | 2007-07-08 15:56:31 +0000 |
commit | 84662c01c901be4cfeee33bdde87e344faa6b1a5 (patch) | |
tree | 01a1e06b74aaf24fe5eadca7df17d266403f5de8 | |
parent | ed5614eb56a4a440d37f20c02c5f323bac53a577 (diff) | |
download | ffmpeg-streaming-84662c01c901be4cfeee33bdde87e344faa6b1a5.zip ffmpeg-streaming-84662c01c901be4cfeee33bdde87e344faa6b1a5.tar.gz |
undef forbidden names before we #define them in case they are macros in libc
Originally committed as revision 9545 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavutil/internal.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libavutil/internal.h b/libavutil/internal.h index 8ee8c8d..af32f56 100644 --- a/libavutil/internal.h +++ b/libavutil/internal.h @@ -234,18 +234,30 @@ if((y)<(x)){\ #endif /* avoid usage of various functions */ +#undef malloc #define malloc please_use_av_malloc +#undef free #define free please_use_av_free +#undef realloc #define realloc please_use_av_realloc +#undef time #define time time_is_forbidden_due_to_security_issues +#undef rand #define rand rand_is_forbidden_due_to_state_trashing_use_av_random +#undef srand #define srand srand_is_forbidden_due_to_state_trashing_use_av_init_random +#undef random #define random random_is_forbidden_due_to_state_trashing_use_av_random +#undef sprintf #define sprintf sprintf_is_forbidden_due_to_security_issues_use_snprintf +#undef strcat #define strcat strcat_is_forbidden_due_to_security_issues_use_av_strlcat +#undef exit #define exit exit_is_forbidden #if !(defined(LIBAVFORMAT_BUILD) || defined(FRAMEHOOK_H)) +#undef printf #define printf please_use_av_log +#undef fprintf #define fprintf please_use_av_log #endif |