aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--conf.c8
-rw-r--r--xevents.c4
-rw-r--r--xutil.c16
3 files changed, 15 insertions, 13 deletions
diff --git a/conf.c b/conf.c
index b49ae6e..ba90add 100644
--- a/conf.c
+++ b/conf.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: conf.c,v 1.123 2013/04/17 13:31:47 okan Exp $
+ * $OpenBSD: conf.c,v 1.124 2013/05/10 16:05:34 okan Exp $
*/
#include <sys/param.h>
@@ -195,7 +195,7 @@ m_binds[] = {
void
conf_init(struct conf *c)
{
- int i;
+ u_int i;
bzero(c, sizeof(*c));
@@ -459,7 +459,7 @@ conf_bindname(struct conf *c, char *name, char *binding)
{
struct keybinding *current_binding;
char *substring, *tmp;
- int i;
+ u_int i;
current_binding = xcalloc(1, sizeof(*current_binding));
@@ -564,7 +564,7 @@ conf_mousebind(struct conf *c, char *name, char *binding)
struct mousebinding *current_binding;
char *substring, *tmp;
const char *errstr;
- int i;
+ u_int i;
current_binding = xcalloc(1, sizeof(*current_binding));
diff --git a/xevents.c b/xevents.c
index d6eb673..8582801 100644
--- a/xevents.c
+++ b/xevents.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: xevents.c,v 1.73 2013/05/10 15:44:43 okan Exp $
+ * $OpenBSD: xevents.c,v 1.74 2013/05/10 16:05:34 okan Exp $
*/
/*
@@ -323,7 +323,7 @@ xev_handle_keyrelease(XEvent *ee)
struct screen_ctx *sc;
struct client_ctx *cc;
KeySym keysym;
- int i;
+ u_int i;
sc = screen_fromroot(e->root);
cc = client_current();
diff --git a/xutil.c b/xutil.c
index 4c8dad1..148e9d7 100644
--- a/xutil.c
+++ b/xutil.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: xutil.c,v 1.57 2013/05/10 15:44:43 okan Exp $
+ * $OpenBSD: xutil.c,v 1.58 2013/05/10 16:05:34 okan Exp $
*/
#include <sys/param.h>
@@ -56,7 +56,8 @@ xu_ptr_ungrab(void)
void
xu_btn_grab(Window win, int mask, u_int btn)
{
- int i;
+ u_int i;
+
for (i = 0; i < nitems(ign_mods); i++)
XGrabButton(X_Dpy, btn, (mask | ign_mods[i]), win,
False, BUTTONMASK, GrabModeAsync,
@@ -66,7 +67,8 @@ xu_btn_grab(Window win, int mask, u_int btn)
void
xu_btn_ungrab(Window win, int mask, u_int btn)
{
- int i;
+ u_int i;
+
for (i = 0; i < nitems(ign_mods); i++)
XUngrabButton(X_Dpy, btn, (mask | ign_mods[i]), win);
}
@@ -91,7 +93,7 @@ void
xu_key_grab(Window win, int mask, KeySym keysym)
{
KeyCode code;
- int i;
+ u_int i;
code = XKeysymToKeycode(X_Dpy, keysym);
if ((XkbKeycodeToKeysym(X_Dpy, code, 0, 0) != keysym) &&
@@ -107,7 +109,7 @@ void
xu_key_ungrab(Window win, int mask, KeySym keysym)
{
KeyCode code;
- int i;
+ u_int i;
code = XKeysymToKeycode(X_Dpy, keysym);
if ((XkbKeycodeToKeysym(X_Dpy, code, 0, 0) != keysym) &&
@@ -258,7 +260,7 @@ struct atom_ctx ewmh[EWMH_NITEMS] = {
void
xu_getatoms(void)
{
- int i;
+ u_int i;
for (i = 0; i < nitems(cwmh); i++)
cwmh[i].atom = XInternAtom(X_Dpy, cwmh[i].name, False);
@@ -271,7 +273,7 @@ void
xu_ewmh_net_supported(struct screen_ctx *sc)
{
Atom atom[EWMH_NITEMS];
- int i;
+ u_int i;
for (i = 0; i < nitems(ewmh); i++)
atom[i] = ewmh[i].atom;