projects
/
ecpprog.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
dd88fc4
)
jtag_tap: Make the MIN macro safer
author
Sylvain Munaut
<tnt@246tNt.com>
Tue, 8 Jun 2021 16:24:16 +0000
(18:24 +0200)
committer
Gregory Davill
<greg.davill@gmail.com>
Wed, 9 Jun 2021 00:37:17 +0000
(10:07 +0930)
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
ecpprog/jtag_tap.c
patch
|
blob
|
history
diff --git
a/ecpprog/jtag_tap.c
b/ecpprog/jtag_tap.c
index c4bdf4ebe9c54616ff610e044d4c8761a6571147..737bc010cfe1b97f86072a55f84652d5387d5943 100644
(file)
--- a/
ecpprog/jtag_tap.c
+++ b/
ecpprog/jtag_tap.c
@@
-214,7
+214,7
@@
static void jtag_shift_bytes(
}
-#define MIN(a,b) (
a < b) ? a : b
+#define MIN(a,b) (
(a) < (b)) ? (a) : (b)
void jtag_tap_shift(
uint8_t *input_data,