[vlc-devel] [PATCH 7/7] include: move more compat functions in extern C block

Rémi Denis-Courmont remi at remlab.net
Mon Aug 3 18:37:20 CEST 2020


Le keskiviikkona 29. heinäkuuta 2020, 14.28.57 EEST Marvin Scholz a écrit :
> This ensures they have the correct linkage declared.

This seems to break the ordering w.r.t. sorting and comments.

> ---
>  include/vlc_fixups.h | 26 +++++++++++++-------------
>  1 file changed, 13 insertions(+), 13 deletions(-)
> 
> diff --git a/include/vlc_fixups.h b/include/vlc_fixups.h
> index 17fa3ed09a..7c746cf699 100644
> --- a/include/vlc_fixups.h
> +++ b/include/vlc_fixups.h
> @@ -282,17 +282,8 @@ int (dirfd) (DIR *);
>  DIR *fdopendir (int);
>  #endif
> 
> -#ifdef __cplusplus
> -} /* extern "C" */
> -#endif
> -
> -/* stdlib.h */
> -#ifndef HAVE_GETENV
> -static inline char *getenv (const char *name)
> -{
> -    (void)name;
> -    return NULL;
> -}
> +#ifndef HAVE_ALIGNED_ALLOC
> +void *aligned_alloc(size_t, size_t);
>  #endif
> 
>  #ifndef HAVE_SETENV
> @@ -304,8 +295,17 @@ int unsetenv (const char *);
>  int posix_memalign(void **, size_t, size_t);
>  #endif
> 
> -#ifndef HAVE_ALIGNED_ALLOC
> -void *aligned_alloc(size_t, size_t);
> +#ifdef __cplusplus
> +} /* extern "C" */
> +#endif
> +
> +/* stdlib.h */
> +#ifndef HAVE_GETENV
> +static inline char *getenv (const char *name)
> +{
> +    (void)name;
> +    return NULL;
> +}
>  #endif
> 
>  #if defined (_WIN32) && defined(__MINGW32__)


-- 
レミ・デニ-クールモン
http://www.remlab.net/





More information about the vlc-devel mailing list