commit ebd63a2aa7dcd1f8eff2ff1caac2998c61572882
parent ab9caa789e9b2ec8d13cc0a808b4c5370679b293
Author: Kris Maglione <jg@suckless.org>
Date: Fri, 2 Oct 2009 16:12:22 -0400
Declare ignored_errors extern in cmd/wmii/x11.c. Fix warning.
Diffstat:
5 files changed, 8 insertions(+), 16 deletions(-)
diff --git a/cmd/menu/main.c b/cmd/menu/main.c
@@ -163,21 +163,8 @@ update_filter(bool print) {
update_input();
}
-/*
- * There's no way to check accesses to destroyed windows, thus
- * those cases are ignored (especially on UnmapNotifies).
- * Other types of errors call Xlib's default error handler, which
- * calls exit().
- */
ErrorCode ignored_xerrors[] = {
- { 0, BadWindow },
- { X_SetInputFocus, BadMatch },
- { X_PolyText8, BadDrawable },
- { X_PolyFillRectangle, BadDrawable },
- { X_PolySegment, BadDrawable },
- { X_ConfigureWindow, BadMatch },
- { X_GrabKey, BadAccess },
- { X_GetAtomName, BadAtom },
+ { 0, }
};
static void
diff --git a/cmd/wmii/area.c b/cmd/wmii/area.c
@@ -80,7 +80,7 @@ area_create(View *v, Area *pos, int scrn, uint width) {
Area *a;
assert(!pos || pos->screen == scrn);
- SET(i);
+ SET(index);
if(v->areas) { /* Creating a column. */
minwidth = column_minwidth();
index = pos ? area_idx(pos) : 1;
diff --git a/cmd/wmii/main.c b/cmd/wmii/main.c
@@ -153,6 +153,7 @@ ErrorCode ignored_xerrors[] = {
{ X_ConfigureWindow, BadMatch },
{ X_GrabKey, BadAccess },
{ X_GetAtomName, BadAtom },
+ { 0, }
};
void
diff --git a/cmd/wmii/x11.c b/cmd/wmii/x11.c
@@ -195,7 +195,7 @@ initdisplay(void) {
/* Error handling */
-ErrorCode ignored_xerrors[];
+extern ErrorCode ignored_xerrors[];
static bool _trap_errors;
static long nerrors;
diff --git a/cmd/wmii9menu.c b/cmd/wmii9menu.c
@@ -81,6 +81,10 @@ void warpmouse(int, int);
void memory(void);
int args(void);
+ErrorCode ignored_xerrors[] = {
+ { 0, }
+};
+
/* main --- crack arguments, set up X stuff, run the main menu loop */
int