From f08b3613b2fd6995da264ea0a39c6d48dd28bf97 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Sun, 10 Feb 2013 19:10:57 -0800 Subject: Rename i & count in inner loop to avoid shadowing same named vars in outer loop xdpyinfo.c: In function `print_dmx_info': xdpyinfo.c:1282: warning: declaration of 'count' shadows a previous local xdpyinfo.c:1231: warning: shadowed declaration is here xdpyinfo.c:1282: warning: declaration of 'i' shadows a previous local xdpyinfo.c:1232: warning: shadowed declaration is here Signed-off-by: Alan Coopersmith --- xdpyinfo.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/xdpyinfo.c b/xdpyinfo.c index 655d672..def5ee6 100644 --- a/xdpyinfo.c +++ b/xdpyinfo.c @@ -1279,15 +1279,15 @@ static int print_dmx_info(Display *dpy, const char *extname) if (ext && ext != (XExtensionVersion *)NoSuchExtension) { - int count, i; + int dcount, d; XDeviceInfo *devInfo = XListInputDevices(backend, - &count); + &dcount); if (devInfo) { - for (i = 0; i < count; i++) { + for (d = 0; d < dcount; d++) { if ((unsigned)iinfo.physicalId - == devInfo[i].id - && devInfo[i].name) { - backendname = strdup(devInfo[i].name); + == devInfo[d].id + && devInfo[d].name) { + backendname = strdup(devInfo[d].name); break; } } -- cgit v1.2.3