diff options
author | cinap_lenrek <cinap_lenrek@felloff.net> | 2017-07-20 21:03:00 +0200 |
---|---|---|
committer | cinap_lenrek <cinap_lenrek@felloff.net> | 2017-07-20 21:03:00 +0200 |
commit | ffb28698bf5922f5d89a0d986fc6ab289fd5b6d3 (patch) | |
tree | 68ef6a79754c844a90d1d3d9c0caf3ba1be0808e /sys/src/9/omap | |
parent | 4fd68773e2c5935b1b5bce0376ced783f87c7934 (diff) |
kernel: fix bounds check in screenputc()
Diffstat (limited to 'sys/src/9/omap')
-rw-r--r-- | sys/src/9/omap/screen.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/9/omap/screen.c b/sys/src/9/omap/screen.c index fe122e4eb..bc4a64b80 100644 --- a/sys/src/9/omap/screen.c +++ b/sys/src/9/omap/screen.c @@ -576,7 +576,7 @@ screenputc(char *buf) static int *xp; static int xbuf[256]; - if (xp < xbuf || xp >= &xbuf[sizeof(xbuf)]) + if (xp < xbuf || xp >= &xbuf[nelem(xbuf)]) xp = xbuf; switch (buf[0]) { |