[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: [2/3] widl: Fix handling of circular imports that involve the file passed on the command line.
From:       Alexandre Julliard <julliard () winehq ! org>
Date:       2015-05-25 12:50:08
Message-ID: 87wpzwstxb.fsf () winehq ! org
[Download RAW message or body]

Francois Gouget <fgouget@free.fr> writes:

> ---
>  tools/widl/parser.l | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/tools/widl/parser.l b/tools/widl/parser.l
> index b911186..2333687 100644
> --- a/tools/widl/parser.l
> +++ b/tools/widl/parser.l
> @@ -488,6 +488,9 @@ int do_import(char *fname)
>  	int ptr = import_stack_ptr;
>  	int ret, fd;
>  
> +	if (strcmp(import_stack_ptr ? import_stack[0].input_name : input_name,
> +	           fname) == 0)
> +		return 0; /* initial source file */

This won't work for out-of-tree builds.

-- 
Alexandre Julliard
julliard@winehq.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic