summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraraujo <araujo@FreeBSD.org>2016-04-27 02:34:25 +0000
committeraraujo <araujo@FreeBSD.org>2016-04-27 02:34:25 +0000
commit725b38abd88adc44c1844f586318cbc771aad4b9 (patch)
tree642db99fb0c89d253ae50d0a7d348649de2d6e87
parent5d5191795554149ec5e274e7898a19f7218cc6b7 (diff)
downloadFreeBSD-src-725b38abd88adc44c1844f586318cbc771aad4b9.zip
FreeBSD-src-725b38abd88adc44c1844f586318cbc771aad4b9.tar.gz
Use MIN() macro from sys/param.h.
MFC after: 2 weeks.
-rw-r--r--usr.bin/tftp/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/tftp/main.c b/usr.bin/tftp/main.c
index dc9ed8c..188ce68 100644
--- a/usr.bin/tftp/main.c
+++ b/usr.bin/tftp/main.c
@@ -727,7 +727,7 @@ command(void)
if (vrbose) {
if ((bp = el_gets(el, &num)) == NULL || num == 0)
exit(0);
- len = (num > MAXLINE) ? MAXLINE : num;
+ len = MIN(MAXLINE, num);
memcpy(line, bp, len);
line[len] = '\0';
history(hist, &he, H_ENTER, bp);
OpenPOWER on IntegriCloud