From: matthieu Date: Tue, 31 Dec 2013 07:16:50 +0000 (+0000) Subject: Fix after struct wscons_event size change. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=889bdbed604554acd1d15a76395f1645d1b3dde0;p=openbsd Fix after struct wscons_event size change. ok deraadt@ --- diff --git a/usr.sbin/ztsscale/ztsscale.c b/usr.sbin/ztsscale/ztsscale.c index 917be15cd7b..2b8319264be 100644 --- a/usr.sbin/ztsscale/ztsscale.c +++ b/usr.sbin/ztsscale/ztsscale.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ztsscale.c,v 1.15 2009/11/10 04:34:38 deraadt Exp $ */ +/* $OpenBSD: ztsscale.c,v 1.16 2013/12/31 07:16:50 matthieu Exp $ */ /* * Copyright (c) 2005 Matthieu Herrb @@ -103,7 +103,7 @@ wait_event(int mfd, int *x, int *y) *x = *y = -1; while (down || *x == -1 || *y == -1) { len = read(mfd, &evbuf, sizeof(evbuf)); - if (len != 16) + if (len != sizeof(evbuf)) break; switch (evbuf.type) { case WSCONS_EVENT_MOUSE_DOWN: