diff options
author | tedu | 2011-02-13 17:25:20 +0000 |
---|---|---|
committer | tedu | 2011-02-13 17:25:20 +0000 |
commit | 5e6fd216c9662fc47cdd29ca0d5400e5dce8c176 (patch) | |
tree | 63c37f91b853f7b3c2fec6c4fc5e083f4fc86f77 /group.c | |
parent | 15e08ff549ea284d28acaac40400aabd7248d891 (diff) | |
download | cwm-5e6fd216c9662fc47cdd29ca0d5400e5dce8c176.tar.gz |
we lose track of highstack somewhere, so recompute it before we need it.
fixes a crash reported by christian neukirchen. ok okan
Diffstat (limited to 'group.c')
-rw-r--r-- | group.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -16,7 +16,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $Id: group.c,v 1.48 2010/09/25 20:01:27 okan Exp $ + * $Id: group.c,v 1.49 2011/02/13 17:25:20 tedu Exp $ */ #include <sys/param.h> @@ -108,6 +108,11 @@ group_show(struct screen_ctx *sc, struct group_ctx *gc) u_int i; int lastempty = -1; + gc->highstack = 0; + TAILQ_FOREACH(cc, &gc->clients, group_entry) { + if (cc->stackingorder > gc->highstack) + gc->highstack = cc->stackingorder; + } winlist = (Window *) xcalloc(sizeof(*winlist), (gc->highstack + 1)); /* |