Re: [hackers] [PATCH][dmenu] Xinerama: correct variable declarations in preprocessor conditional

From: Quentin Rameau <quinq_AT_fifth.space>
Date: Fri, 25 Nov 2016 11:57:13 +0100

> Greetings,
Hi,

> The config.mk option must never have been rigorously tested.
Thank you for spotting that, but maybe the description, if any, could
be a little more constructive?

> ---
> dmenu.c | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/dmenu.c b/dmenu.c
> index 9278e91..6512844 100644
> --- a/dmenu.c
> +++ b/dmenu.c
> _AT_@ -544,11 +544,13 @@ setup(void)
> XIM xim;
> #ifdef XINERAMA
> XineramaScreenInfo *info;
> - Window w, pw, dw, *dws;
> + Window pw;
> + int a, j, di, n, area = 0;
> +#endif
> + Window w, dw, *dws;
> XWindowAttributes wa;
> - int a, j, di, n, i = 0, area = 0;
> unsigned int du;
> -#endif
> + int i = 0;
>
> /* init appearance */
> scheme[SchemeNorm] = drw_scm_create(drw, colors[SchemeNorm],
> 2);
Just put all common declarations above the ifdef
Received on Fri Nov 25 2016 - 11:57:13 CET

This archive was generated by hypermail 2.3.0 : Fri Nov 25 2016 - 12:00:18 CET