Re: js/win-lazyload-buildfix (was Re: What's cooking in git.git (Sep 2021, #07; Thu, 23))

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 24.09.21 um 11:14 schrieb Carlo Marcelo Arenas Belón:
> Subject: [PATCH] fixup! lazyload.h: fix warnings about mismatching function
>  pointer types
> 
> The original patch will require the declaration this macro creates
> to be moved to the end of the local variables or will trigger
> -Wdeclaration-after-statement because it will likely end in ";;" if
> the macro call has one, as it is common.
> 
> Remove trailing ';' from macro definition, for easy of use.
> 
> Signed-off-by: Carlo Marcelo Arenas Belón <carenas@xxxxxxxxx>
> ---
>  compat/win32/lazyload.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/compat/win32/lazyload.h b/compat/win32/lazyload.h
> index c688e545ad..2b3637135f 100644
> --- a/compat/win32/lazyload.h
> +++ b/compat/win32/lazyload.h
> @@ -29,7 +29,7 @@ struct proc_addr {
>  	static struct proc_addr proc_addr_##function = \
>  	{ #dll, #function, NULL, 0 }; \
>  	typedef rettype (WINAPI *proc_type_##function)(__VA_ARGS__); \
> -	static proc_type_##function function;
> +	static proc_type_##function function
>  
>  /*
>   * Loads a function from a DLL (once-only).
> 

Good find! This looks correct. The trailing semicolon was not present
before I added it with my change. Thank you very much for fixing up my
carelessness.

-- Hannes



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux