# HG changeset patch # User ib # Date 1358540942 0 # Node ID f6470f5787b9a669184a2cb303c171fb72a89b70 # Parent 411ae24eef28e9453730f105468c07ad5d3d507d Make variables local. A global scope isn't necessary. diff -r 411ae24eef28 -r f6470f5787b9 gui/wm/ws.c --- a/gui/wm/ws.c Fri Jan 18 17:53:44 2013 +0000 +++ b/gui/wm/ws.c Fri Jan 18 20:29:02 2013 +0000 @@ -68,16 +68,6 @@ static wsWindow *mouse_win; static unsigned int mouse_time; -typedef struct { - unsigned long flags; - unsigned long functions; - unsigned long decorations; - long input_mode; - unsigned long status; -} MotifWmHints; - -static Atom wsMotifHints; - int wsMaxX; // Screen width. int wsMaxY; // Screen height. int wsOrgX; // Screen origin x. @@ -1014,14 +1004,21 @@ void wsWindowDecoration(wsWindow *win, Bool decor) { - MotifWmHints wsMotifWmHints; + Atom wsMotifHints; + struct { + unsigned long flags; + unsigned long functions; + unsigned long decorations; + long input_mode; + unsigned long status; + } wsMotifWmHints; wsMotifHints = XInternAtom(wsDisplay, "_MOTIF_WM_HINTS", 0); if (wsMotifHints == None) return; - memset(&wsMotifWmHints, 0, sizeof(MotifWmHints)); + memset(&wsMotifWmHints, 0, sizeof(wsMotifWmHints)); wsMotifWmHints.flags = MWM_HINTS_FUNCTIONS | MWM_HINTS_DECORATIONS; if (decor) {