diff options
| author | Bryan Cantrill <bryan@joyent.com> | 2019-02-04 21:36:58 +0000 |
|---|---|---|
| committer | John Levon <john.levon@joyent.com> | 2019-03-01 11:11:54 +0000 |
| commit | 92c1a61163ff6a0655b27bd429856e171e7ce5f5 (patch) | |
| tree | 0d976392cefaf1c3a2aea9d415c2d86c5eb43d46 /usr/src/lib/libsaveargs | |
| parent | 6d3b6de806befb1050c80e5d4be2214ee68fb2b7 (diff) | |
| download | illumos-joyent-92c1a61163ff6a0655b27bd429856e171e7ce5f5.tar.gz | |
10468 __ctype_mask[EOF] has been working by accident
10469 GCC's -faggressive-loop-optimizations is too aggressive
10470 array over-read in has_saved_fp()
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: John Levon <john.levon@joyent.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Reviewed by: Andy Fiddaman <andy@omniosce.org>
Reviewed by: Gergő Doma <domag02@gmail.com>
Reviewed by: Gary Mills <gary_mills@fastmail.fm>
Approved by: Richard Lowe <richlowe@richlowe.net>
Diffstat (limited to 'usr/src/lib/libsaveargs')
| -rw-r--r-- | usr/src/lib/libsaveargs/Makefile.com | 5 | ||||
| -rw-r--r-- | usr/src/lib/libsaveargs/amd64/saveargs.c | 9 |
2 files changed, 7 insertions, 7 deletions
diff --git a/usr/src/lib/libsaveargs/Makefile.com b/usr/src/lib/libsaveargs/Makefile.com index 94d80c1d5b..883afb66c9 100644 --- a/usr/src/lib/libsaveargs/Makefile.com +++ b/usr/src/lib/libsaveargs/Makefile.com @@ -22,7 +22,7 @@ # Copyright 2007 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# Copyright (c) 2018, Joyent, Inc. +# Copyright (c) 2019, Joyent, Inc. # # The build process for libsaveargs is sightly different from that used by other @@ -95,9 +95,6 @@ CFLAGS += $(CFLAGS_$(CURTYPE)) $(CFLAGS_common) CFLAGS64_standalone = $(STAND_FLAGS_64) CFLAGS64 += $(CCVERBOSE) $(CFLAGS64_$(CURTYPE)) $(CFLAGS64_common) -# not linted -SMATCH=off - DYNFLAGS += $(ZINTERPOSE) .KEEP_STATE: diff --git a/usr/src/lib/libsaveargs/amd64/saveargs.c b/usr/src/lib/libsaveargs/amd64/saveargs.c index f07ef354c1..6d3ed769f2 100644 --- a/usr/src/lib/libsaveargs/amd64/saveargs.c +++ b/usr/src/lib/libsaveargs/amd64/saveargs.c @@ -23,6 +23,9 @@ * Use is subject to license terms. */ +/* + * Copyright 2019 Joyent, Inc. + */ /* * The Sun Studio and GCC (patched for opensolaris/illumos) compilers @@ -217,7 +220,7 @@ instr_size(dis_handle_t *dhp, uint8_t *ins, unsigned int i, size_t size) static boolean_t has_saved_fp(dis_handle_t *dhp, uint8_t *ins, int size) { - int i, j; + int i, j; uint32_t n; boolean_t found_push = B_FALSE; ssize_t sz = 0; @@ -231,7 +234,7 @@ has_saved_fp(dis_handle_t *dhp, uint8_t *ins, int size) continue; n = INSTR1(ins, i); - for (j = 0; j <= NUM_FP_PUSHES; j++) + for (j = 0; j < NUM_FP_PUSHES; j++) if (save_fp_pushes[j] == n) { found_push = B_TRUE; break; @@ -240,7 +243,7 @@ has_saved_fp(dis_handle_t *dhp, uint8_t *ins, int size) if (sz != 3) continue; n = INSTR3(ins, i); - for (j = 0; j <= NUM_FP_MOVS; j++) + for (j = 0; j < NUM_FP_MOVS; j++) if (save_fp_movs[j] == n) return (B_TRUE); } |
