diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-09-24 18:32:19 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-09-24 18:32:19 +0000 |
commit | 5809de6815f215e331bcdb2a7dc104ea093df7d2 (patch) | |
tree | d7cbd008d79a50feb5112c483b5b199c4b10473a /sys | |
parent | 613596a195ba9bf7e47ee17625a23813af8c989b (diff) |
Don't compare array against null pointer; found by clang.
ok jca@, jcs@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/i2c/iatp.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/i2c/iatp.c b/sys/dev/i2c/iatp.c index d97a6de36ba..5dae7908cba 100644 --- a/sys/dev/i2c/iatp.c +++ b/sys/dev/i2c/iatp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: iatp.c,v 1.2 2016/09/04 10:45:29 jsg Exp $ */ +/* $OpenBSD: iatp.c,v 1.3 2016/09/24 18:32:18 kettenis Exp $ */ /* * Atmel maXTouch i2c touchscreen/touchpad driver * Copyright (c) 2016 joshua stein <jcs@openbsd.org> @@ -548,8 +548,7 @@ iatp_init(struct iatp_softc *sc) /* find this machine's button config */ sc->t19_button_bit = -1; - if (hw_vendor == NULL || hw_prod == NULL || - sc->sc_hid == NULL) + if (hw_vendor == NULL || hw_prod == NULL) break; for (m = mxt_t19_button_map_devs; m->vendor != NULL; |